void FatalExit(nErrCode) | |||||
int nErrCode; | /* error value to display | */ |
The FatalExit function sends the current state of Windows to the debugger and prompts for instructions on how to proceed.
An application should call this function for debugging purposes only; it should not call the function in a retail version of the application. Calling this function in the retail version will terminate the application.
nErrCode
Specifies the error value to be displayed.
This function does not return a value.
The displayed information includes an error value followed by a symbolic stack trace, showing the flow of execution up to the point of the call.
The FatalExit function prompts the user to respond to an Abort, Break, or Ignore message. Windows processes the response as follows:
Response | Description |
A (Abort) | Terminate immediately. |
B (Break) | Enter the debugger. |
I (Ignore) | Return to the caller. |
You can specify any combination of error values for the nErrCode parameter, since the meaning of the values is unique to your application. However, the error value –1 must always be reserved for the stack-overflow message. When this value is specified, Windows automatically displays a stack-overflow message.