This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH] Fix memory leak in printf_positional
- From: OndÅej BÃlka <neleai at seznam dot cz>
- To: Paul Pluzhnikov <ppluzhnikov at google dot com>
- Cc: Carlos O'Donell <carlos at redhat dot com>, Joseph Myers <joseph at codesourcery dot com>, Paul Eggert <eggert at cs dot ucla dot edu>, GLIBC Devel <libc-alpha at sourceware dot org>
- Date: Sat, 5 Sep 2015 08:30:01 +0200
- Subject: Re: [PATCH] Fix memory leak in printf_positional
- Authentication-results: sourceware.org; auth=none
- References: <1440571295-20230-1-git-send-email-eggert at cs dot ucla dot edu> <alpine dot DEB dot 2 dot 10 dot 1508260930500 dot 26898 at digraph dot polyomino dot org dot uk> <55DFB7C7 dot 50307 at redhat dot com> <alpine dot DEB dot 2 dot 10 dot 1508281350520 dot 5939 at digraph dot polyomino dot org dot uk> <55E06924 dot 2000209 at redhat dot com> <CALoOobMkGafD9zvq9g13TM8_Nd+HmC58_8gMGTQhdefXpko3CA at mail dot gmail dot com> <20150830042956 dot GA3968 at domone> <CALoOobNC_tY6AZrHBU5P=Ss=Vo_4-DkmsHFxJ8Jw9Xid-PA24w at mail dot gmail dot com>
On Sat, Aug 29, 2015 at 09:35:43PM -0700, Paul Pluzhnikov wrote:
> On Sat, Aug 29, 2015 at 9:29 PM, OndÅej BÃlka <neleai@seznam.cz> wrote:
>
> > There is also problem what this would catch, as in future a problem
> > could be with 65536 arguments or other magical constant this isn't that
> > much useful.
>
> Sorry, you lost me.
>
> The test case catches the existing bug that the patch at the start of
> this thread fixes.
>
> I am sure there other bugs that this test doesn't catch, and I am sure
> there could be new bugs in the future that require more arguments to
> catch. I don't think these are good reasons not to have a test.
>
Just that it doesn't make sense to add specific test for bugs that have very
narrow use case and are fixed as it won't catch similar ones with sligth
variation of parameters. Instead I would try to make generic tests that
would catch wider class of bugs.