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

Re: Bug#935902: libcppunit-dev: segfault when using with a program compiled with g++-9



[ Cc'ing the GCC maintainers ]

Hi,

On Tue, Aug 27, 2019 at 03:47:50PM +0200, Sorin Manolache wrote:
> When compiling a program with g++-9 (4:9.2.1-3) and linking with libcppunit
> then I get a segfault if the program uses std::stack.

Hrmpf.

> For example:
> 
> void f() {
>     std::stack<std::string> s1;
>     std::stack<unsigned int> s2;
> 
>     std::string str;
>     CPPUNIT_ASSERT(r.empty()); // segfault here
> }

That isn't a complete testcase? r doesn't exist (did you mean str?) or
some of s1,s2 (empty stack)?

Does it only happen if you CPPUNT_ASSERT it or also on "normal"
std::stack usage? But I assume you file it here because it only happens
with cppunit?

> It suffices to rebuild the package by compiling it with g++-9 and the segfault
> does not occur any more.

Strictly speaking this would be a bug (or some known change?) in
gcc/libstdc++6 then?

Regards,

Rene


Reply to: