about summary refs log tree commit diff
path: root/Src/Zle
diff options
context:
space:
mode:
authorBart Schaefer <barts@users.sourceforge.net>2000-10-22 02:34:16 +0000
committerBart Schaefer <barts@users.sourceforge.net>2000-10-22 02:34:16 +0000
commitde595fbc90aafdb6987576fcf7b9f1dd9a2a2d2b (patch)
tree9662008f4925892561ad9bd501290c431836356b /Src/Zle
parent9bf7fb75c55d3ac23c47d5af0d96f4e1af727222 (diff)
downloadzsh-de595fbc90aafdb6987576fcf7b9f1dd9a2a2d2b.tar.gz
zsh-de595fbc90aafdb6987576fcf7b9f1dd9a2a2d2b.tar.xz
zsh-de595fbc90aafdb6987576fcf7b9f1dd9a2a2d2b.zip
Fix "vared -e".
Diffstat (limited to 'Src/Zle')
-rw-r--r--Src/Zle/zle_main.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/Src/Zle/zle_main.c b/Src/Zle/zle_main.c
index 675dda63e..b2d075f91 100644
--- a/Src/Zle/zle_main.c
+++ b/Src/Zle/zle_main.c
@@ -748,7 +748,7 @@ bin_vared(char *name, char **args, char *ops, int func)
     struct value vbuf;
     Value v;
     Param pm = 0;
-    int create = 0, ifl;
+    int create = 0, ifl, ieof;
     int type = PM_SCALAR, obreaks = breaks, haso = 0;
     char *p1 = NULL, *p2 = NULL;
     FILE *oshout = NULL;
@@ -900,11 +900,13 @@ bin_vared(char *name, char **args, char *ops, int func)
 
     varedarg = *args;
     ifl = isfirstln;
-    if (ops['e'])
-	isfirstln = 1;
     if (ops['h'])
 	hbegin(2);
+    isfirstln = ops['e'];
+    ieof = opts[IGNOREEOF];
+    opts[IGNOREEOF] = 0;
     t = (char *) zleread(p1, p2, ops['h'] ? ZLRF_HISTORY : 0);
+    opts[IGNOREEOF] = ieof;
     if (ops['h'])
 	hend(NULL);
     isfirstln = ifl;