summaryrefslogtreecommitdiff
path: root/Src/Zle/zle_tricky.c
diff options
context:
space:
mode:
authorPeter Stephenson <pws@zsh.org>2015-09-01 11:45:23 +0100
committerPeter Stephenson <pws@zsh.org>2015-09-01 11:45:23 +0100
commit21382e0b20c697e83d0bc903a5e17b75e5979995 (patch)
tree755fae7743f0c726b6190d059e8927880f92d198 /Src/Zle/zle_tricky.c
parentb73e4442e850a565525b7ed75f2a7b01698499d6 (diff)
downloadzsh-21382e0b20c697e83d0bc903a5e17b75e5979995.tar.gz
zsh-21382e0b20c697e83d0bc903a5e17b75e5979995.zip
36365: magic-space could delete the reset of the line.
If we got a LEXERR, which didn't necessarily mean an actual error, just something the rather nasty ctxtlex() got confused by, we didn't scan the reset of the line.
Diffstat (limited to 'Src/Zle/zle_tricky.c')
-rw-r--r--Src/Zle/zle_tricky.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/Src/Zle/zle_tricky.c b/Src/Zle/zle_tricky.c
index 97bdcc020..b1a6f9e7e 100644
--- a/Src/Zle/zle_tricky.c
+++ b/Src/Zle/zle_tricky.c
@@ -2812,6 +2812,8 @@ doexpandhist(void)
do {
ctxtlex();
} while (tok != ENDINPUT && tok != LEXERR);
+ if (tok == LEXERR)
+ lexstop = 0;
while (!lexstop)
hgetc();
/* We have to save errflags because it's reset in zcontext_restore. Since *