summary refs log tree commit diff
path: root/Src/Zle
diff options
context:
space:
mode:
Diffstat (limited to 'Src/Zle')
-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  *