Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

PATCH: segfaults in history search with bindkey -v



I could have sworn that I sent this hours ago..

The problem is that vipenultsrchstr is getting double-freed sometimes.

Index: Src/Zle/zle_hist.c
===================================================================
RCS file: /cvsroot/zsh/zsh/Src/Zle/zle_hist.c,v
retrieving revision 1.36
diff -u -r1.36 zle_hist.c
--- Src/Zle/zle_hist.c	10 Sep 2006 18:10:49 -0000	1.36
+++ Src/Zle/zle_hist.c	13 Sep 2007 09:53:52 -0000
@@ -1240,6 +1240,7 @@
 
     if (vipenultsrchstr) {
 	zsfree(vipenultsrchstr);
+	vipenultsrchstr = NULL;
     }
 
     if (visrchstr) {



Messages sorted by: Reverse Date, Date, Thread, Author