Skip to content

Commit

Permalink
fixup: use arrays, reintroduce semicola
Browse files Browse the repository at this point in the history
  • Loading branch information
Peter G. (nephros) committed Mar 15, 2021
1 parent 4f9c7e0 commit 967f332
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions tools/restart_network.sh
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
#!/bin/sh

warning() {
printf "%s: Warning: %s\n" "$(basename $0)" "$*" 1>&2
printf "%s: Warning: %s\n" "$(basename $0)" "${@}" 1>&2;
}

service_do() {
if systemctl $1 $2; then
return 0
if systemctl "$1" "$2"; then
return 0;
else
warning "Status $? on $*"
return 1
warning "Status $? on" "${@}"
return 1;
fi
}

Expand Down

0 comments on commit 967f332

Please sign in to comment.