diff options
author | Christian Hesse <mail@eworm.de> | 2024-12-06 10:31:52 +0100 |
---|---|---|
committer | Christian Hesse <mail@eworm.de> | 2024-12-09 11:49:50 +0100 |
commit | 90cfa83d95baf440544a331fd60f9903afa1fead (patch) | |
tree | 7ea42ac7b1c2263d15b306f658fd819cc61fc9b4 | |
parent | 923a6385bf8fcb770a70650318d96f0571d7297e (diff) |
gps-track: use $ExitError to indicate unintentional error
-rw-r--r-- | gps-track.rsc | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/gps-track.rsc b/gps-track.rsc index a2ea9ff..c0ecac4 100644 --- a/gps-track.rsc +++ b/gps-track.rsc @@ -11,6 +11,7 @@ :global GlobalFunctionsReady; :while ($GlobalFunctionsReady != true) do={ :delay 500ms; } +:local ExitOK false; :do { :local ScriptName [ :jobname ]; @@ -23,6 +24,7 @@ :global WaitFullyConnected; :if ([ $ScriptLock $ScriptName ] = false) do={ + :set ExitOK true; :error false; } $WaitFullyConnected; @@ -45,4 +47,6 @@ } else={ $LogPrint debug $ScriptName ("GPS data not valid."); } -} on-error={ } +} on-error={ + :global ExitError; $ExitError $ExitOK [ :jobname ]; +} |