Operating system exceptions in critical functions generally occur only if your program passes a pointer that is not valid to a library function, or if your program overwrites the library's data areas. Because calling a signal handler to handle an exception from one of these functions can have unexpected results, a special exception handler is provided for critical functions. You cannot override this exception handler.
If the exception is synchronous (SIGFPE, SIGILL, or SIGSEGV), the default action is taken, which is to pass the exception on to the next registered exception handler. Any exception handler you may have registered will not be called, and will receive only the termination exception.
The handling of asynchronous exceptions is deferred until the library function has finished. The exception is then passed to _Exception, which converts the exception to the corresponding C signal and performs the appropriate action.
![]()
Signals and Exceptions
Signal and Exception Handling