about summary refs log tree commit diff
path: root/Src/loop.c
diff options
context:
space:
mode:
Diffstat (limited to 'Src/loop.c')
-rw-r--r--Src/loop.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/Src/loop.c b/Src/loop.c
index fd63edb5a..3432c384f 100644
--- a/Src/loop.c
+++ b/Src/loop.c
@@ -178,8 +178,13 @@ execselect(Cmd cmd, LinkList args, int flags)
 	for (;;) {
 	    if (empty(bufstack)) {
 	    	if (interact && SHTTY != -1 && isset(USEZLE)) {
+		    int oef = errflag;
+
 		    isfirstln = 1;
 		    str = (char *)zleread(prompt3, NULL, 0);
+		    if (errflag)
+			str = NULL;
+		    errflag = oef;
 	    	} else {
 		    str = promptexpand(prompt3, 0, NULL, NULL);
 		    zputs(str, stderr);