Re: [RFC PATCH libiberty] Fix infinite recursion in demangler

2017-03-12 Thread Mark Wielaard
On Wed, 2017-03-08 at 09:05 -0500, Nathan Sidwell wrote: > thanks. in case you'd not noticed Ian T's okayed my review. so this is > good to go Thanks. Markus pushed it including the testcases. But there are still two testcase (not added, but attached below) that are still failing (but now

Re: [RFC PATCH libiberty] Fix infinite recursion in demangler

2017-03-08 Thread Nathan Sidwell
On 03/08/2017 08:29 AM, Mark Wielaard wrote: On Wed, 2017-03-08 at 08:22 -0500, Nathan Sidwell wrote: https://gcc.gnu.org/ml/gcc-patches/2017-03/msg00089.html? Patch looks good to me (not a libiberty maintainer) One question: + if (dc == NULL || dc->d_printing > 1) Can dc ever be null here,

Re: [RFC PATCH libiberty] Fix infinite recursion in demangler

2017-03-08 Thread Mark Wielaard
On Wed, 2017-03-08 at 08:22 -0500, Nathan Sidwell wrote: > https://gcc.gnu.org/ml/gcc-patches/2017-03/msg00089.html? > > Patch looks good to me (not a libiberty maintainer) > > One question: > + if (dc == NULL || dc->d_printing > 1) > > Can dc ever be null here, or is this just extra

[RFC PATCH libiberty] Fix infinite recursion in demangler

2017-03-08 Thread Nathan Sidwell
https://gcc.gnu.org/ml/gcc-patches/2017-03/msg00089.html? Patch looks good to me (not a libiberty maintainer) One question: + if (dc == NULL || dc->d_printing > 1) Can dc ever be null here, or is this just extra defensiveness? nathan -- Nathan Sidwell

Re: [RFC PATCH libiberty] Fix infinite recursion in demangler

2017-03-02 Thread Mark Wielaard
Hi, On Thu, 2017-03-02 at 10:36 +0100, Markus Trippelsdorf wrote: > The following patch from Mark Wielaard fixes many (all?) open demangler > bugs that happen because we overflow the stack due to infinite > recursion. > > I'm not sure why Mark didn't post the patch himself. > Anyway here it is.

[RFC PATCH libiberty] Fix infinite recursion in demangler

2017-03-02 Thread Markus Trippelsdorf
The following patch from Mark Wielaard fixes many (all?) open demangler bugs that happen because we overflow the stack due to infinite recursion. I'm not sure why Mark didn't post the patch himself. Anyway here it is. Any comments? Thanks. diff --git a/include/demangle.h b/include/demangle.h