From f4134784de0f4e5fb282ef4215463fa955f599ef Mon Sep 17 00:00:00 2001 From: Roger Luethi Date: Mon, 25 Aug 2014 19:58:43 +0200 Subject: [PATCH] labs: exit after unhandled option If the user supplies an unhandled option, the script should stop. With this patch, it does. Change-Id: If7b490cf8e4f11dcead16b8dee6e6fa6e4aa2f59 --- labs/osbash.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/labs/osbash.sh b/labs/osbash.sh index cfd6326f..12410eb4 100755 --- a/labs/osbash.sh +++ b/labs/osbash.sh @@ -75,6 +75,8 @@ while getopts efhnw opt; do ;; ?) echo "Error: unhandled option $opt" + echo + usage ;; esac done