diff options
author | P. J. McDermott <pj@pehjota.net> | 2016-01-17 09:36:12 (EST) |
---|---|---|
committer | P. J. McDermott <pj@pehjota.net> | 2016-01-17 09:36:12 (EST) |
commit | 00b51a0659bc5ac7fb2e5898172f2e4b90a2b104 (patch) | |
tree | 79d3a6261849e5739a016bf66461c436e93ca5fd /src | |
parent | f47b3b16676ec60d37cd6614b53844ebc26aad61 (diff) |
main(): Switch to non-exiting error()
Diffstat (limited to 'src')
-rw-r--r-- | src/main.sh | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/main.sh b/src/main.sh index dae02d0..e034104 100644 --- a/src/main.sh +++ b/src/main.sh @@ -66,7 +66,12 @@ main() case "${cmd}" in 'help'|'version') ;; - *) check_uid || error 1 "$(get_msg 'uid_0_req')";; + *) + if ! check_uid; then + error "$(get_msg 'uid_0_req')" + return 1 + fi + ;; esac run_cmd "${cmd}" "${@}" |