1

I know Windows seperatly builds a Structered Exception Handling Chain for each running thread within a process. I was wondering if with veh, the registered exception handler will be called process wide (no matter in what threat the exception occured) or was also registered on a per thread basis?

Don
  • 1,428
  • 3
  • 15
  • 31
  • This is easy to just try by yourself, start a thread and have it dereference a null pointer. Your callback runs on whatever thread triggered the exception. – Hans Passant Feb 16 '15 at 16:00

1 Answers1

2

Yes, vectored exception handlers are process wide.

From MSDN:

An application can register a function to watch or handle all exceptions for the application. Vectored handlers are not frame-based, therefore, you can add a handler that will be called regardless of where you are in a call frame.

New Vectored Exception Handling in Windows XP by Matt Pietrek states:

The handler list is not tied to any thread, and is global to the process.

ge0rdi
  • 261
  • 3
  • 6