aboutsummaryrefslogtreecommitdiff
path: root/shell/hush.c
diff options
context:
space:
mode:
Diffstat (limited to 'shell/hush.c')
-rw-r--r--shell/hush.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/shell/hush.c b/shell/hush.c
index b612c80da..a103e8169 100644
--- a/shell/hush.c
+++ b/shell/hush.c
@@ -6132,6 +6132,12 @@ static int encode_then_append_var_plusminus(o_string *output, int n,
/* string has no special chars
* && string has no $IFS chars
*/
+ if (dquoted) {
+ /* Prints 1 (quoted expansion is a "" word, not nothing):
+ * set -- "${notexist-}"; echo $#
+ */
+ output->has_quoted_part = 1;
+ }
return expand_vars_to_list(output, n, str);
}