Fix default exit code of bailout
authorMykola Malkov <mmalkov@sipwise.com>
Thu, 5 Apr 2018 13:40:02 +0000 (15:40 +0200)
committerMykola Malkov <mmalkov@sipwise.com>
Thu, 5 Apr 2018 13:40:02 +0000 (15:40 +0200)
Exit code 0 if the funciton is called without arguments

sbin/netcardconfig

index fc4e645..83cac2b 100755 (executable)
@@ -21,7 +21,7 @@ TMP=$(mktemp)
 
 bailout() {
   rm -f "$TMP"
-  exit "$1"
+  exit "${1:-0}"
 }
 
 # This function produces the IWOURLINE for interfaces