diff options
author | 2015-08-03 13:18:48 +0000 | |
---|---|---|
committer | 2015-08-03 13:18:48 +0000 | |
commit | a6638285f599cc6bdba37fbc54699695722d32c5 (patch) | |
tree | 497dc64560e86f5f639190dea7ff923ab4285415 | |
parent | Fix rev 1.70 of server.c by only re-enabling the bufferevent if we (diff) | |
download | wireguard-openbsd-a6638285f599cc6bdba37fbc54699695722d32c5.tar.xz wireguard-openbsd-a6638285f599cc6bdba37fbc54699695722d32c5.zip |
"ls" requires an argument.
issue reported by kirby@
"hurry up" deraadt@
-rw-r--r-- | usr.sbin/rcctl/rcctl.sh | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/usr.sbin/rcctl/rcctl.sh b/usr.sbin/rcctl/rcctl.sh index db8ed582833..31368227f58 100644 --- a/usr.sbin/rcctl/rcctl.sh +++ b/usr.sbin/rcctl/rcctl.sh @@ -1,6 +1,6 @@ #!/bin/sh # -# $OpenBSD: rcctl.sh,v 1.77 2015/08/01 11:28:14 ajacoutot Exp $ +# $OpenBSD: rcctl.sh,v 1.78 2015/08/03 13:18:48 ajacoutot Exp $ # # Copyright (c) 2014, 2015 Antoine Jacoutot <ajacoutot@openbsd.org> # Copyright (c) 2014 Ingo Schwarze <schwarze@openbsd.org> @@ -426,6 +426,7 @@ shift $((OPTIND-1)) action=$1 if [ "${action}" = "ls" ]; then lsarg=$2 + [[ ${lsarg} == @(all|faulty|off|on|started|stopped) ]] || usage elif [ "${action}" = "order" ]; then shift 1 svcs="$*" @@ -436,9 +437,6 @@ else args="$*" fi -[ -n "${lsarg}" ] && [[ ${lsarg} != @(all|faulty|off|on|started|stopped) ]] && \ - usage - if [ -n "${svc}" ]; then [[ ${action} == @(disable|enable|get|getdef|set|start|stop|restart|reload|check) ]] || \ usage |