about 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_main.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/Src/Zle/zle_main.c b/Src/Zle/zle_main.c
index 0ac45431d..6acedee70 100644
--- a/Src/Zle/zle_main.c
+++ b/Src/Zle/zle_main.c
@@ -633,7 +633,7 @@ raw_getbyte(long do_keytmout, char *cptr)
 	    /*
 	     * Make sure a user interrupt gets passed on straight away.
 	     */
-	    if (selret < 0 && errflag)
+	    if (selret < 0 && (errflag || retflag || breaks || exit_pending))
 		break;
 	    /*
 	     * Try to avoid errors on our special fd's from
@@ -875,7 +875,7 @@ getbyte(long do_keytmout, int *timeout)
 	    icnt = 0;
 	    if (errno == EINTR) {
 		die = 0;
-		if (!errflag && !retflag && !breaks)
+		if (!errflag && !retflag && !breaks && !exit_pending)
 		    continue;
 		errflag = 0;
 		breaks = obreaks;