diff options
Diffstat (limited to 'bin/sh/eval.c')
-rw-r--r-- | bin/sh/eval.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/bin/sh/eval.c b/bin/sh/eval.c index fa2fe59..dc0236d 100644 --- a/bin/sh/eval.c +++ b/bin/sh/eval.c @@ -643,14 +643,19 @@ evalcommand(union node *cmd, int flags, struct backcmd *backcmd) /* Print the command if xflag is set. */ if (xflag) { - outc('+', &errout); + char sep = 0; + out2str(ps4val()); for (sp = varlist.list ; sp ; sp = sp->next) { - outc(' ', &errout); + if (sep != 0) + outc(' ', &errout); out2str(sp->text); + sep = ' '; } for (sp = arglist.list ; sp ; sp = sp->next) { - outc(' ', &errout); + if (sep != 0) + outc(' ', &errout); out2str(sp->text); + sep = ' '; } outc('\n', &errout); flushout(&errout); |