This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Segmentation fault when exception is thrown or assertion fails [g++/gcc]


I get the following output:

      4 [sig] a 1408 _cygtls::handle_exceptions: Error while dumping
state (probably corrupted stack)
Segmentation fault (core dumped)

When running the following test programs:

#include <assert.h>

int main(void)
{
    assert( 1 == 0 );
    return 0;
}

or

#include <cassert>
#include <stdexcept>

int main()
{
    throw new std::runtime_error("Just because"); // the same with
assert(false);
}

I am using gcc-3.4.4.

I understand that Cygwin defaults to dumping the stack trace, but why
the message about segmentation fault? It confuses the hell out of me.

Regards,
Roman Werpachowski

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]