fw-addr-lists: early exit with :exit

This commit is contained in:
Christian Hesse 2026-01-19 15:14:54 +01:00
parent 3bad246473
commit df4c2b84d9

View file

@ -8,7 +8,6 @@
# download, import and update firewall address-lists # download, import and update firewall address-lists
# https://rsc.eworm.de/doc/fw-addr-lists.md # https://rsc.eworm.de/doc/fw-addr-lists.md
:local ExitOK false;
:onerror Err { :onerror Err {
:global GlobalConfigReady; :global GlobalFunctionsReady; :global GlobalConfigReady; :global GlobalFunctionsReady;
:retry { :if ($GlobalConfigReady != true || $GlobalFunctionsReady != true) \ :retry { :if ($GlobalConfigReady != true || $GlobalFunctionsReady != true) \
@ -46,8 +45,7 @@
} }
:if ([ $ScriptLock $ScriptName ] = false) do={ :if ([ $ScriptLock $ScriptName ] = false) do={
:set ExitOK true; :exit;
:error false;
} }
$WaitFullyConnected; $WaitFullyConnected;
@ -232,5 +230,5 @@
" - removed: " . [ $HumanReadableNum $CntRemove 1000 ]); " - removed: " . [ $HumanReadableNum $CntRemove 1000 ]);
} }
} do={ } do={
:global ExitError; $ExitError $ExitOK [ :jobname ] $Err; :global ExitError; $ExitError false [ :jobname ] $Err;
} }