Opened 16 years ago

Closed 16 years ago

#3140 closed bug (invalid)

SIGSEGV handler not called upon stack overflow

Reported by: bhaible Owned by: axeld
Priority: normal Milestone: R1
Component: System/Kernel Version: R1/pre-alpha1
Keywords: Cc:
Blocked By: Blocking:
Platform: All

Description

After installing a SIGSEGV handler and an alternate stack (and verifying that both the sigaction and sigaltstack system calls succeeded!), a stack overflow still does not invoke the SIGSEGV handler.

Expected behaviour of the attach program: A message on stderr, either "program error" or "stack overflow".

Actual behaviour: A dialog allowing to debug the program. If I enter Debug, then "continue", the error message on stderr is "Segmentation violation" - the handler was still not caught.

This works on BeOS.

Attachments (2)

stack-overflow-bug.c (1.8 KB ) - added by bhaible 16 years ago.
test program provoking a stack overflow
haiku-long-double-bug.png (8.3 KB ) - added by bhaible 16 years ago.
screenshot of dialog appearing

Download all attachments as: .zip

Change History (4)

by bhaible, 16 years ago

Attachment: stack-overflow-bug.c added

test program provoking a stack overflow

by bhaible, 16 years ago

Attachment: haiku-long-double-bug.png added

screenshot of dialog appearing

comment:1 by bhaible, 16 years ago

Oops, my mistake. When I add SA_ONSTACK to the sigaction flags, the signal handler is called.

You can close or trash this ticket.

comment:2 by anevilyak, 16 years ago

Resolution: invalid
Status: newclosed

Thanks for the note!

Note: See TracTickets for help on using tickets.