summaryrefslogtreecommitdiff
path: root/Src/prompt.c
diff options
context:
space:
mode:
Diffstat (limited to 'Src/prompt.c')
-rw-r--r--Src/prompt.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/Src/prompt.c b/Src/prompt.c
index 72ba2e244..36eaca3e9 100644
--- a/Src/prompt.c
+++ b/Src/prompt.c
@@ -169,6 +169,12 @@ promptexpand(char *s, int ns, char *rs, char *Rs, unsigned int *txtchangep)
s = dupstring(s);
if (!parsestr(s))
singsub(&s);
+ /*
+ * We don't need the special Nularg hack here and we're
+ * going to be using Nularg for other things.
+ */
+ if (*s == Nularg && s[1] == '\0')
+ *s = '\0';
/* Ignore errors and status change in prompt substitution */
errflag = olderr;