zsh-workers
 help / color / mirror / code / Atom feed
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: Sun, 30 Apr 2023 09:51:42 +0000	[thread overview]
Message-ID: <CAKc7PVAZ23GhqwajyxQHB3gWnpH_DoWXobY2pG6tkpvHgsw1nw@mail.gmail.com> (raw)
In-Reply-To: <CAKc7PVDV98OLcb+0QY7ANmkLdMOKV=TncgsOfZqa=Cmoap+yiw@mail.gmail.com>

Is the info not sufficient? What else could I check?

On Sat, 29 Apr 2023 at 10:52, Sebastian Gniazdowski
<sgniazdowski@gmail.com> wrote:
>
> It says "incomplete sequence \339"  although egrep $'\330' ~/.zhistory
> doesn't return anything…
>
> (gdb) frame
> #1  0x00007ffff7e1f628 in histwgetfn (pm=0x508f70) at parameter.c:1241
> 1241                addlinknode(l, dupstring(h));
> (gdb) l
> 1236            for (iw = he->nwords - 1; iw >= 0; iw--) {
> 1237                h = he->node.nam + he->words[iw * 2];
> 1238                e = he->node.nam + he->words[iw * 2 + 1];
> 1239                sav = *e;
> 1240                *e = '\0';
> 1241                addlinknode(l, dupstring(h));
> 1242                *e = sav;
> 1243            }
> 1244            he = up_histent(he);
> 1245        }
>
> (gdb) p he->node.nam + he->words[iw*2]
> $31 = 0x7ffff7ae1370 <incomplete sequence \330>
> (gdb) p he->node.nam + he->words[iw*2+1]
> $32 = 0x7ffff7ae1371 ""
> (gdb) p he->node.nam + he->words[(iw-1)*2]
> $33 = 0x7ffff7ae134f ""
> (gdb) p he->node.nam + he->words[(iw-1)*2+1]
> $34 = 0x7ffff7ae1370 <incomplete sequence \330>
>
> I agree that the resilience to incomplete chars should be strengthened.
>
> Is iw the event number?
> (gdb) p iw
> $35 = 51475
>
> Because history 51474 doesn't return any \330 char either:
> 51474  angel open
> 51475  angel open
> 51476  angel open
>
> On Fri, 28 Apr 2023 at 14:22, Peter Stephenson
> <p.w.stephenson@ntlworld.com> wrote:
> >
> > > On 28/04/2023 15:13 Sebastian Gniazdowski <sgniazdowski@gmail.com> wrote:
> > > I'm searching for an empty word, i.e.: I'm just pressing alt-/ right
> > > after the shell has started.
> >
> > The crash is when the shell is putting together what's already in your
> > history into a set of words, so it can use them from completing.  If
> > you look at the string that is being pared in "bufferwords" at the
> > point of the crash, which comes from the history entry "he", you should
> > see a line from your previous command line history.  That's probably
> > causing the shell some problems --- although there's always the
> > possibility it might be a previous history entry that's messed things
> > up, but this is the place to look first.
> >
> > What you're searching for / completing probably isn't all that important.
> >
> > Hmm, come to think of it a bit of safety combined with a DPUTS() might
> > help with both aspects --- I'll see if I've got time for that over
> > the weekend.
> >
> > pws
> >
>
>
> --
> Best regards,
> Sebastian Gniazdowski



-- 
Best regards,
Sebastian Gniazdowski


  reply	other threads:[~2023-04-30  9:52 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
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 [this message]
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=CAKc7PVAZ23GhqwajyxQHB3gWnpH_DoWXobY2pG6tkpvHgsw1nw@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).