#include // Raise from main thread. void foo() { raise(SIGSEGV); } void bar() { foo(); } void qux() { bar(); } int main() { qux(); }