I registered a handler of SIGSEGV
, using fprintf
to print some message then exit. The process prints the message but did not exit. It blocked before exit()
.
Can't I use exit()
to finish the process normally in the handler?
void sigsegv__handler(){
fprintf(stderr, "SIGSEGV , TID: %d,PID: %d\n", TEST_ID, getpid());
exit(1);
}