2
votes
1answer
723 views

sigaction(7): semantics of siginfo_t's si_code member

I've got a long-running program (becomes a daemon with daemon(3) call) that exits on Signal 11 (Segmentation Violation) every so often. I can't tell why. So, I wrote a SIGSEGV handler, set using the ...
3
votes
2answers
4k views

How can I trap a program that returns 139 (segmentation fault) in bash?

I have a bash script that tests some programs and one of the program returns Segmentation fault so I tried to add a trap in the head of my script: trap "echo 'segfault occured!'" SIGSEGV That ...