Issue Details (XML | Word | Printable)

Key: STDCXX-600
Type: Bug Bug
Status: Open Open
Priority: Minor Minor
Assignee: Eric Lemings
Reporter: Martin Sebor
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
C++ Standard Library

[gcc 4.0.1/Mac OS X] SIGABRT throwing an exception

Created: 16/Oct/07 04:27 PM   Updated: 20/Jan/09 02:04 AM
Return to search
Component/s: 18. Language Support
Affects Version/s: 4.2.0, 4.2.1
Fix Version/s: 4.2.2

Time Tracking:
Original Estimate: 4h
Original Estimate - 4h
Remaining Estimate: 4h
Remaining Estimate - 4h
Time Spent: Not Specified
Remaining Estimate - 4h

Environment: gcc 4.0.1 on Darwin Kernel Version 8.10.1
Issue Links:
Reference
 

Severity: Runtime Error


 Description  « Hide
Throwing an exception from the library causes a SIGABRT. Example programs that demonstrate library exceptions abort, as does the program below:

$ cat t.cpp && make t && gdb -q t
#include <string>

int main ()
{
try { std::string s; s.replace (1, 1, "x"); }
catch (...) {
}
}

gcc -c -I/Users/sebor/stdcxx/include/ansi -D_RWSTDDEBUG -I/Users/sebor/stdcxx/include -I/build/sebor/stdcxx-gcc-4.0.1-15d/include -I/Users/sebor/stdcxx/examples/include -pedantic -nostdinc++ -g -W -Wall -Wcast-qual -Winline -Wshadow -Wwrite-strings -Wno-long-long -Wcast-align t.cpp
gcc t.o -o t -L/build/sebor/stdcxx-gcc-4.0.1-15d/lib -lstd15d -lsupc++ -lgcc_eh -lm
Reading symbols for shared libraries ... done
(gdb) run
Starting program: /build/sebor/stdcxx-gcc-4.0.1-15d/examples/t
Reading symbols for shared libraries .+ done

Program received signal SIGABRT, Aborted.
0x9003d66c in kill ()
(gdb) where
#0 0x9003d66c in kill ()
#1 0x9010e8cf in raise ()
#2 0x9010d422 in abort ()
#3 0x00002959 in _Unwind_SetGR () at t.cpp:11
#4 0x000026a6 in __gxx_personality_v0 () at t.cpp:11
#5 0x002681c4 in _Unwind_RaiseException_Phase2 () at /Users/sebor/stdcxx/src/wctype.cpp:1058
#6 0x002683f4 in _Unwind_RaiseException () at /Users/sebor/stdcxx/src/wctype.cpp:1058
#7 0x00260a57 in __cxa_throw () at /Users/sebor/stdcxx/src/wctype.cpp:1058
#8 0x0020b774 in _rw::_rw_throw_exception (id=9, what=0x11001d0 "") at /Users/sebor/stdcxx/src/exception.cpp:694
#9 0x0020ac40 in _rw::_rw_throw (id=9) at /Users/sebor/stdcxx/src/exception.cpp:832
#10 0x00238149 in std::string::replace (this=0xbffffa88, __pos1=1, __n1=1, __s=0xbac8 "x", __n2=1) at /Users/sebor/stdcxx/include/string.cc:312
#11 0x0023852f in std::string::replace (this=0xbffffa88, __pos=1, __n=1, __s=0xbac8 "x") at /Users/sebor/stdcxx/include/string:545
#12 0x00001c4d in main () at t.cpp:7



 All   Comments   Work Log   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
Martin Sebor made changes - 16/Oct/07 04:39 PM
Field Original Value New Value
Link This issue is related to STDCXX-262 [ STDCXX-262 ]
Martin Sebor made changes - 02/May/08 01:21 AM
Affects Version/s trunk [ 12312676 ]
Affects Version/s 4.2.1 [ 12312690 ]
Martin Sebor made changes - 02/May/08 01:26 AM
Affects Version/s 4.2.0 [ 12311945 ]
Martin Sebor made changes - 14/May/08 06:12 PM
Fix Version/s 4.2.2 [ 12313096 ]
Assignee Eric Lemings [ elemings ]
Original Estimate 4h [ 14400 ]
Remaining Estimate 4h [ 14400 ]
Martin Sebor made changes - 20/Jan/09 02:04 AM
Priority Critical [ 2 ] Minor [ 4 ]