From: Sebastian Gniazdowski <sgniazdowski@gmail.com>
To: Peter Stephenson <p.w.stephenson@ntlworld.com>
Cc: Zsh hackers list <zsh-workers@zsh.org>
Subject: Re: [BUG] sigsegv
Date: Fri, 28 Apr 2023 11:25:17 +0000 [thread overview]
Message-ID: <CAKc7PVC1Lm=iYHXM5MHSfOiGdHKdgD6nV1fnjn+-pok24Z5L_A@mail.gmail.com> (raw)
In-Reply-To: <886115150.3264962.1682430985767@mail.virginmedia.com>
It looks like the last field is incorrect:
(gdb) up
#1 0x00007ffff7e1f628 in histwgetfn (pm=0x508e10)
at parameter.c:1241
1241 addlinknode(l, dupstring(h));
(gdb) p *l->list->last
Cannot access memory at address 0x7ffff5350068
On Tue, 25 Apr 2023 at 13:56, Peter Stephenson
<p.w.stephenson@ntlworld.com> wrote:
>
> > On 25/04/2023 14:48 Sebastian Gniazdowski <sgniazdowski@gmail.com> wrote:
> > I have to say that current HEAD has many sigsegv errors, at least twp.
> > The reported in this email is an older problem with alt-/ history
> > complete, I've had it also with 5.8. I'm still waiting for the 5.9
> > only problem to occur, it's quite random and hard to reproduce.
> > To trigger the error, press alt-/ some times.
> >
> > #0 0x0000000000457868 in insertlinknode (list=list@entry=0x7ffff7abe368,
> > node=0x7ffff55600d8, dat=0x7ffff556e8f0) at linklist.c:137
> > #1 0x00007ffff7bed6bf in histwgetfn (pm=<optimized out>) at parameter.c:1241
>
> The linked list management itself looks fairly harmless, but I wonder if there's
> something in the immediately surrounding code that could be fishy and messing
> up memory?
>
> for (iw = he->nwords - 1; iw >= 0; iw--) {
> h = he->node.nam + he->words[iw * 2];
> e = he->node.nam + he->words[iw * 2 + 1];
> sav = *e;
> *e = '\0';
> addlinknode(l, dupstring(h));
> *e = sav;
> }
>
> Some testing of strlen(he->node.nam) might not come amiss?
>
> Of course this is total guesswork.
>
> pws
>
--
Best regards,
Sebastian Gniazdowski
next prev parent reply other threads:[~2023-04-28 11:26 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-04-25 13:48 Sebastian Gniazdowski
2023-04-25 13:56 ` Peter Stephenson
2023-04-28 11:25 ` Sebastian Gniazdowski [this message]
2023-04-28 11:41 ` Peter Stephenson
2023-04-28 14:13 ` Sebastian Gniazdowski
2023-04-28 14:22 ` Peter Stephenson
2023-04-29 10:52 ` Sebastian Gniazdowski
2023-04-30 9:51 ` Sebastian Gniazdowski
2023-04-30 17:30 ` Peter Stephenson
2023-05-03 15:35 ` Sebastian Gniazdowski
2023-05-03 15:56 ` Sebastian Gniazdowski
2023-05-03 16:25 ` Peter Stephenson
2023-05-03 21:13 ` Bart Schaefer
[not found] ` <CAKc7PVDt6hS26DxC3hDE-ziMXm-K1jqbJXghynpp-ZhpdN_LLw@mail.gmail.com>
2023-05-04 15:01 ` Bart Schaefer
2023-05-05 18:54 ` Peter Stephenson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAKc7PVC1Lm=iYHXM5MHSfOiGdHKdgD6nV1fnjn+-pok24Z5L_A@mail.gmail.com' \
--to=sgniazdowski@gmail.com \
--cc=p.w.stephenson@ntlworld.com \
--cc=zsh-workers@zsh.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).