diff --git a/capsman-download-packages.capsman.rsc b/capsman-download-packages.capsman.rsc index 8cedf01b..be09795d 100644 --- a/capsman-download-packages.capsman.rsc +++ b/capsman-download-packages.capsman.rsc @@ -11,7 +11,6 @@ # # !! Do not edit this file, it is generated from template! -:local ExitOK false; :onerror Err { :global GlobalConfigReady; :global GlobalFunctionsReady; :retry { :if ($GlobalConfigReady != true || $GlobalFunctionsReady != true) \ @@ -28,8 +27,7 @@ :global WaitFullyConnected; :if ([ $ScriptLock $ScriptName ] = false) do={ - :set ExitOK true; - :error false; + :exit; } $WaitFullyConnected; @@ -39,16 +37,14 @@ :if ([ :len $PackagePath ] = 0) do={ $LogPrint warning $ScriptName ("The CAPsMAN package path is not defined, can not download packages."); - :set ExitOK true; - :error false; + :exit; } :if ([ $FileGet $PackagePath ] = false) do={ :if ([ $MkDir $PackagePath ] = false) do={ $LogPrint warning $ScriptName ("Creating directory at CAPsMAN package path (" . \ $PackagePath . ") failed!"); - :set ExitOK true; - :error false; + :exit; } $LogPrint info $ScriptName ("Created directory at CAPsMAN package path (" . $PackagePath . \ "). Please place your packages!"); @@ -89,5 +85,5 @@ } } } do={ - :global ExitError; $ExitError $ExitOK [ :jobname ] $Err; + :global ExitError; $ExitError false [ :jobname ] $Err; } diff --git a/capsman-download-packages.template.rsc b/capsman-download-packages.template.rsc index ffb622ba..14a45962 100644 --- a/capsman-download-packages.template.rsc +++ b/capsman-download-packages.template.rsc @@ -12,7 +12,6 @@ # !! This is just a template to generate the real script! # !! Pattern '%TEMPL%' is replaced, paths are filtered. -:local ExitOK false; :onerror Err { :global GlobalConfigReady; :global GlobalFunctionsReady; :retry { :if ($GlobalConfigReady != true || $GlobalFunctionsReady != true) \ @@ -29,8 +28,7 @@ :global WaitFullyConnected; :if ([ $ScriptLock $ScriptName ] = false) do={ - :set ExitOK true; - :error false; + :exit; } $WaitFullyConnected; @@ -41,16 +39,14 @@ :if ([ :len $PackagePath ] = 0) do={ $LogPrint warning $ScriptName ("The CAPsMAN package path is not defined, can not download packages."); - :set ExitOK true; - :error false; + :exit; } :if ([ $FileGet $PackagePath ] = false) do={ :if ([ $MkDir $PackagePath ] = false) do={ $LogPrint warning $ScriptName ("Creating directory at CAPsMAN package path (" . \ $PackagePath . ") failed!"); - :set ExitOK true; - :error false; + :exit; } $LogPrint info $ScriptName ("Created directory at CAPsMAN package path (" . $PackagePath . \ "). Please place your packages!"); @@ -100,5 +96,5 @@ } } } do={ - :global ExitError; $ExitError $ExitOK [ :jobname ] $Err; + :global ExitError; $ExitError false [ :jobname ] $Err; } diff --git a/capsman-download-packages.wifi.rsc b/capsman-download-packages.wifi.rsc index 1aefee63..6b1da82f 100644 --- a/capsman-download-packages.wifi.rsc +++ b/capsman-download-packages.wifi.rsc @@ -11,7 +11,6 @@ # # !! Do not edit this file, it is generated from template! -:local ExitOK false; :onerror Err { :global GlobalConfigReady; :global GlobalFunctionsReady; :retry { :if ($GlobalConfigReady != true || $GlobalFunctionsReady != true) \ @@ -28,8 +27,7 @@ :global WaitFullyConnected; :if ([ $ScriptLock $ScriptName ] = false) do={ - :set ExitOK true; - :error false; + :exit; } $WaitFullyConnected; @@ -39,16 +37,14 @@ :if ([ :len $PackagePath ] = 0) do={ $LogPrint warning $ScriptName ("The CAPsMAN package path is not defined, can not download packages."); - :set ExitOK true; - :error false; + :exit; } :if ([ $FileGet $PackagePath ] = false) do={ :if ([ $MkDir $PackagePath ] = false) do={ $LogPrint warning $ScriptName ("Creating directory at CAPsMAN package path (" . \ $PackagePath . ") failed!"); - :set ExitOK true; - :error false; + :exit; } $LogPrint info $ScriptName ("Created directory at CAPsMAN package path (" . $PackagePath . \ "). Please place your packages!"); @@ -91,5 +87,5 @@ } } } do={ - :global ExitError; $ExitError $ExitOK [ :jobname ] $Err; + :global ExitError; $ExitError false [ :jobname ] $Err; }