summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog5
-rw-r--r--Src/Zle/zle_tricky.c4
2 files changed, 8 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index 95196f7a8..15fb5d7fa 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2000-08-29 Sven Wischnowsky <wischnow@zsh.org>
+
+ * 12717: Src/Zle/zle_tricky.c: fix for unbalanced calls to
+ {push,pop}heap in docomplete()/get_comp_string()
+
2000-08-28 Bart Schaefer <schaefer@zsh.org>
* 12716: Doc/Zsh/builtins.yo, Doc/Zsh/compctl.yo,
diff --git a/Src/Zle/zle_tricky.c b/Src/Zle/zle_tricky.c
index 63978175d..f9ba965db 100644
--- a/Src/Zle/zle_tricky.c
+++ b/Src/Zle/zle_tricky.c
@@ -581,7 +581,8 @@ docomplete(int lst)
qisuf = ztrdup("");
zsfree(autoq);
autoq = NULL;
- /* Get the word to complete. */
+ /* Get the word to complete.
+ * NOTE: get_comp_string() calls pushheap(), but not popheap(). */
noerrs = 1;
s = get_comp_string();
DPUTS(wb < 0 || cs < wb || cs > we,
@@ -603,6 +604,7 @@ docomplete(int lst)
strcpy((char *) line, ol);
ll = strlen((char *) line);
cs = ocs;
+ popheap();
unmetafy_line();
zsfree(s);
zsfree(qword);