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

Re: Bug#924736: zsh 5.7.1 segfaults when three setopt options are in play [origin: wesley@xxxxxxxxxxxxx]

Hello all,


> Haven't had time to bisect this, but I got this backtrace from git

On #zsh (thanks okdana, Mikachu and DHowett) we noticed that the bug
was introduced between 5.3.1 and 5.6.2.
I managed to bisect and the bug seems to originate from
Once that commit is reverted the bug disappears. Mikachu noticed that
if one applies the patch below the problem is also resolved. My
understanding of the zsh code base is limited, so I don't feel
confident to submit the patch for actual inclusion in the code base:

diff --git i/Src/hist.c w/Src/hist.c
index dbdc1e4e5..972a36db2 100644
--- i/Src/hist.c
+++ w/Src/hist.c
@@ -1489,7 +1489,7 @@ hend(Eprog prog)
} else
save = 0;
-       if (chwordpos <= 2 && !hist_keep_comment)
+       if (chwordpos <= 2)
save = 0;
else if (should_ignore_line(prog))
save = -1;


Wesley Schwengle, Developer
Mintlab B.V., https://www.zaaksysteem.nl
E: wesley@xxxxxxxxxx
T:  +31 20 737 00 05

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