From: Alejandro Colomar Date: Sun, 22 Dec 2024 14:21:15 +0000 (+0100) Subject: src/bin/diffman: Fix bug at parsing options X-Git-Tag: man-pages-6.10~43 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=1c8ede9f6cc7da0354e7cc6d5e1d6ca6aa860779;p=thirdparty%2Fman-pages.git src/bin/diffman: Fix bug at parsing options We don't want multiple cases to match the option. The '*)' was matching any option. Fixes: f2dfd79facf0 (2024-12-13, "src/bin/diffman: Add default case") Signed-off-by: Alejandro Colomar --- diff --git a/src/bin/diffman b/src/bin/diffman index 921905c7e..172a825ec 100755 --- a/src/bin/diffman +++ b/src/bin/diffman @@ -22,11 +22,11 @@ err() while getopts "sU:w" opt; do case "$opt" in - s) s='-s'; ;;& - U) u="-U$OPTARG"; ;;& - w) w='-w'; ;;& - \?) exit 1; ;;& - *) exit 1; ;;& + s) s='-s'; ;; + U) u="-U$OPTARG"; ;; + w) w='-w'; ;; + \?) exit 1; ;; + *) exit 1; ;; esac; done; shift $((OPTIND-1));