From 95e3f5ee751930c56be731d664b02aae5400dd0d Mon Sep 17 00:00:00 2001 From: "Gary V. Vaughan" Date: Thu, 11 Oct 2012 00:32:10 +0700 Subject: [PATCH] options-parser: keep non-option arguments separate! * build-aux/options-parser (func_parse_options): When there is more than one non-option argument, "$*" forces all of them into a single string. Use ${1+"$@"} to set arguments correctly. Signed-off-by: Gary V. Vaughan --- build-aux/options-parser | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build-aux/options-parser b/build-aux/options-parser index 3c4f788ab..86d52db07 100644 --- a/build-aux/options-parser +++ b/build-aux/options-parser @@ -495,7 +495,7 @@ func_parse_options () --) set dummy "$_G_opt" "*"; shift; break ;; -*) func_fatal_help "unrecognised option: \`$_G_opt'" ;; - *) set dummy "$_G_opt" "$*"; shift; break ;; + *) set dummy "$_G_opt" ${1+"$@"}; shift; break ;; esac done -- 2.47.3