[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [bug-patch] Broken patch commit: don't warn twice about the same inv

From: Jean Delvare
Subject: Re: [bug-patch] Broken patch commit: don't warn twice about the same invalid file name
Date: Tue, 10 Apr 2012 15:50:44 +0200
User-agent: KMail/1.12.4 (Linux/; KDE/4.3.5; i686; ; )

Hi Andreas,

On Friday 06 April 2012 03:06:47 pm Andreas Gr├╝nbacher wrote:
> Am 6. April 2012 14:09 schrieb Jean Delvare <address@hidden>:
> > This commit [...] is broken.
> > bad[] holds pointers to the name strings, and these get freed
> > when switching to the next hunk in the patch file (if I read the
> > code properly...) So you end up accessing freed memory. Valgrind
> > complains about that and the code will eventually fail, as was
> > reported by an openSUSE user:
> >
> > https://bugzilla.novell.com/show_bug.cgi?id=755136
> >
> > I don't think the code even actually does what it is supposed to,
> > as it can only store 2 bad names (the slots are never freed), while
> > a given patch file could contain a lot more.
> Thanks. We are actually only interested in each patch here, not in
>  all the patches that could be in the same input file. How about the
>  attached change for a fix?

I tested your fix and it works OK, the result is as expected now and 
valgrind is happy too. Thanks!

Jean Delvare
Suse L3

reply via email to

[Prev in Thread] Current Thread [Next in Thread]