Exception handling problem
I'm a bit new to programming for Linux so i was suprised that try..catch block didn't catch an exception that was trown when my code was trying to write something to the beginning of RAM. I only saw "SegmentationFault" as program output so i'm wondering how to handle segmentation faults in C++ on Linux. Thanks in advance.
ubuntu jaunty amd64
In C++ try/catch blocks are only guaranteed to catch C++ exceptions: exceptions thrown with the throw keyword. Segmentation faults are handled with POSIX signals on linux, in particular, SIGSEGV. For more information use man signal.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement