This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/43324] New: core dump on throw
- From: "lwestermann at gams dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 10 Mar 2010 18:19:58 -0000
- Subject: [Bug c++/43324] New: core dump on throw
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
$uname -a
SunOS sigvmec2 5.11 snv_111b i86pc i386 i86xpv Solaris
$g++ -v
Using built-in specs.
Target: i386-pc-solaris2.11
Configured with: ../configure CC=gcc --prefix=/usr/local2
--build=i386-pc-solaris2.11 --with-gnu-as --with-as=/usr/local/bin/as
--without-gnu-ld --with-ld=/usr/ccs/bin/ld --with-gmp=/usr/local
--with-mpfr=/usr/local --enable-languages=c,c++,fortran --enable-shared
Thread model: posix
gcc version 4.4.3 (GCC)
Source code:
#include <iostream>
using namespace std;
int main() {
cout << "hello world!" << endl;
try {
throw "exception";
} catch ( ... ) {
cout << "catched exception" << endl ;
}
return 0;
}
If I compile this with:
g++ -m64 test.c -o test
and run ./test, I get
hello world!
terminate called after throwing an instance of 'char const*'
Abort (core dumped)
With gcc 4.3.3 it works without a problem.
Best,
Lutz
--
Summary: core dump on throw
Product: gcc
Version: 4.4.3
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: lwestermann at gams dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43324