index : pacman | |
Archlinux32 fork of pacman | gitolite user |
summaryrefslogtreecommitdiff |
author | Dave Reisner <dreisner@archlinux.org> | 2013-01-01 22:43:20 -0500 |
---|---|---|
committer | Allan McRae <allan@archlinux.org> | 2013-01-03 12:03:09 +1000 |
commit | 60d258819294e7b84c7ec501d9bfe6fe6965d41c (patch) | |
tree | badf93362c922b97116ed8c5098ca57805a2ab7e /scripts/library/parseopts.sh | |
parent | 1dd3405813434e71ead02bdcb66b6da0544632c4 (diff) |
-rw-r--r-- | scripts/library/parseopts.sh | 6 |
diff --git a/scripts/library/parseopts.sh b/scripts/library/parseopts.sh index 11589ce3..cf6aa6c6 100644 --- a/scripts/library/parseopts.sh +++ b/scripts/library/parseopts.sh @@ -92,26 +92,22 @@ parseopts() { # --longopt else OPTRET+=("--$opt") - shift - continue 2 fi ;; 1) # --longopt=optarg if [[ $optarg ]]; then OPTRET+=("--$opt" "$optarg") - shift # --longopt optarg elif [[ $2 ]]; then OPTRET+=("--$opt" "$2" ) - shift 2 + shift # parse failure else printf "@SCRIPTNAME@: $(gettext "option '%s' requires an argument")\n" "--$opt" >&2 OPTRET=(--) return 1 fi - continue 2 ;; 254) # ambiguous option -- error was reported for us by longoptmatch() |