Travis Vitek (JIRA) wrote:
[ https://issues.apache.org/jira/browse/STDCXX-938?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
[...]
I've reduced the problem to the following testcase...
I haven't looked at it very closely -- is this a compiler bug? Martin
{noformat} [EMAIL PROTECTED] tests]$ cat t.cpp; aCC -g t.cpp; gdb a.out extern "C" { typedef void rw_signal_handler_t (int); } rw_signal_handler_t* const rw_sig_ign = (rw_signal_handler_t*)-2; unsigned rw_alarm (rw_signal_handler_t* handler) { if (rw_sig_ign == handler) { return 4; } else if (handler) { return 5; } return 0; } extern "C" { void my_signal_handler (int) { } } int main () { rw_alarm (my_signal_handler); return 0; } HP gdb 5.0 for PA-RISC 1.1 or 2.0 (narrow), HP-UX 11.00 and target hppa1.1-hp-hpux11.00. Copyright 1986 - 2001 Free Software Foundation, Inc. Hewlett-Packard Wildebeest 5.0 (based on GDB) is covered by the GNU General Public License. Type "show copying" to see the conditions to change it and/or distribute copies. Type "show warranty" for warranty/support. .. (gdb) runStarting program: /build/vitek/4.2.2/12s/tests/a.out Program received signal SIGSEGV, Segmentation faultsi_code: 0 - SEGV_UNKNOWN - Unknown Error. 0x2d60 in rw_alarm (handler=0x4000113a <my_signal_handler>) at t.cpp:9 9 if (rw_sig_ign == handler) { (gdb) where #0 0x2d60 in rw_alarm (handler=0x4000113a <my_signal_handler>) at t.cpp:9 #1 0x2df0 in main () at t.cpp:26 {noformat}
