about summary refs log tree commit diff
diff options
context:
space:
mode:
authorSven Wischnowsky <wischnow@users.sourceforge.net>2000-05-04 08:43:30 +0000
committerSven Wischnowsky <wischnow@users.sourceforge.net>2000-05-04 08:43:30 +0000
commit4f80c3fedf8c45e07b70d069b0f59b36b8278be5 (patch)
tree43840a16b33ebf8e3bf38e00a3445c251538061c
parent4414e16a6a958c39209f37f7f7a6fae6b1b78864 (diff)
downloadzsh-4f80c3fedf8c45e07b70d069b0f59b36b8278be5.tar.gz
zsh-4f80c3fedf8c45e07b70d069b0f59b36b8278be5.tar.xz
zsh-4f80c3fedf8c45e07b70d069b0f59b36b8278be5.zip
save and restore `len' in lexsave/restore (11142)
-rw-r--r--ChangeLog2
-rw-r--r--Src/lex.c3
2 files changed, 5 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index 9896bf9fb..5532b0fb6 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,7 @@
 2000-05-04  Sven Wischnowsky  <wischnow@informatik.hu-berlin.de>
 
+	* 11142: Src/lex.c: save and restore `len' in lexsave/restore
+	
 	* 11140: Completion/Builtins/_zstyle, Completion/Core/_main_complete,
  	Doc/Zsh/compsys.yo, Src/Zle/compcore.c, Src/Zle/compctl.c: don't
  	list when all matches look the same; force-list style to give
diff --git a/Src/lex.c b/Src/lex.c
index ccd04b2d9..6ba6b49b0 100644
--- a/Src/lex.c
+++ b/Src/lex.c
@@ -178,6 +178,7 @@ struct lexstack {
     char *yytext;
     char *bptr;
     int bsiz;
+    int len;
     short *chwords;
     int chwordlen;
     int chwordpos;
@@ -236,6 +237,7 @@ lexsave(void)
     ls->yytext = yytext;
     ls->bptr = bptr;
     ls->bsiz = bsiz;
+    ls->len = len;
     ls->chwords = chwords;
     ls->chwordlen = chwordlen;
     ls->chwordpos = chwordpos;
@@ -296,6 +298,7 @@ lexrestore(void)
     yytext = lstack->yytext;
     bptr = lstack->bptr;
     bsiz = lstack->bsiz;
+    len = lstack->len;
     chwords = lstack->chwords;
     chwordlen = lstack->chwordlen;
     chwordpos = lstack->chwordpos;