_RTC_SetErrorFuncW
Designates a function as the handler for the reporting of run-time error checks (RTCs).
_RTC_error_fnW _RTC_SetErrorFuncW( _RTC_error_fnW function );
In new code, use only _RTC_SetErrorFuncW. _RTC_SetErrorFunc is only included in the library for backward compatibility.
The _RTC_SetErrorFuncW callback applies only to the component that it was linked in, but not globally.
Make sure that the address that you pass to _RTC_SetErrorFuncW is that of a valid error handling function.
If an error has been assigned a type of –1 by using _RTC_SetErrorType, the error handling function is not called.
Before you can call this function, you must first call one of the run-time error-check initialization functions. For more information, see Using Run-Time Checks Without the C Run-Time Library.
_RTC_error_fnW is defined as follows:
typedef int (__cdecl *_RTC_error_fnW)(int errorType , const wchar_t * filename , int linenumber , const wchar_t * moduleName , const wchar_t * format , ...);
where:
For an example that shows how to use _RTC_error_fnW, see Native Run-Time Checks Customization.
|
Routine |
Required header |
|---|---|
|
_RTC_SetErrorFuncW |
<rtcapi.h> |
For more information, see Compatibility.
Libraries
All versions of the C run-time libraries.
Not applicable. To call the standard C function, use PInvoke. For more information, see Platform Invoke Examples.