about summary refs log tree commit diff
path: root/Src
diff options
context:
space:
mode:
Diffstat (limited to 'Src')
-rw-r--r--Src/Zle/zle_move.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/Src/Zle/zle_move.c b/Src/Zle/zle_move.c
index f49df8647..155fda80d 100644
--- a/Src/Zle/zle_move.c
+++ b/Src/Zle/zle_move.c
@@ -344,6 +344,8 @@ endofline(char **args)
 	    zlecs = zlell;
 	    return 0;
 	}
+	if ((zlecs += invicmdmode()) == zlell)
+	    break;
 	if (zleline[zlecs] == '\n')
 	    if (++zlecs == zlell)
 		return 0;
@@ -414,6 +416,8 @@ endoflinehist(char **args)
 	    zlecs = zlell;
 	    break;
 	}
+	if ((zlecs += invicmdmode()) == zlell)
+	    break;
 	if (zleline[zlecs] == '\n')
 	    if (++zlecs == zlell)
 		break;