"GOT", but the "O" is a cute, smiling pufferfish. Index | Thread | Search

From:
"Johannes Thyssen Tishman" <johannes@thyssentishman.com>
Subject:
Re: segfault when recursively unstaging removed file
To:
"Stefan Sperling" <stsp@stsp.name>
Cc:
<gameoftrees@openbsd.org>
Date:
Mon, 07 Oct 2024 14:07:11 +0200

Download raw body.

Thread
2024-10-07T11:53:03Z Stefan Sperling:
> On Mon, Oct 07, 2024 at 12:56:25PM +0200, Johannes Thyssen Tishman wrote:
> > I know this is a very weird scenario and probably something that
> > shouldn't be done. Nevertheless I thought I'd report this. Please find
> > the backtrace attached.
> > 
> > Steps to reproduce:
> > 
> > mkdir -p foo/bar
> > touch foo/bar/file
> > got init foobar.git
> > got import -r foobar.git -m 'test' foo
> > got checkout foobar.git
> > cd foobar
> > echo 'blah' > bar/file
> > got stage bar/file
> > mv bar/file bar/new_file
> > got unstage bar
> > 
> > $ got -V
> > got 0.104-current
>
>
> Thanks, the patch below fixes this crash and adds test coverage.

Thanks Stefan. I can confirm that with this patch applied, I can't
reproduce the segfault anymore.