Skip to content

Latest commit

 

History

History
59 lines (43 loc) · 3.34 KB

get-invalid-parameter-handler-get-thread-local-invalid-parameter-handler.md

File metadata and controls

59 lines (43 loc) · 3.34 KB
description title ms.date api_name api_location api_type topic_type f1_keywords helpviewer_keywords ms.assetid
Learn more about: _get_invalid_parameter_handler, _get_thread_local_invalid_parameter_handler
_get_invalid_parameter_handler, _get_thread_local_invalid_parameter_handler
4/2/2020
_get_invalid_parameter_handler
_get_thread_local_invalid_parameter_handler
_o__get_invalid_parameter_handler
_o__get_thread_local_invalid_parameter_handler
msvcrt.dll
msvcr80.dll
msvcr90.dll
msvcr100.dll
msvcr100_clr0400.dll
msvcr110.dll
msvcr110_clr0400.dll
msvcr120.dll
msvcr120_clr0400.dll
ucrtbase.dll
api-ms-win-crt-runtime-l1-1-0.dll
DLLExport
apiref
_get_invalid_parameter_handler
stdlib/_get_invalid_parameter_handler
_get_thread_local_invalid_parameter_handler
stdlib/_get_thread_local_invalid_parameter_handler
_get_thread_local_invalid_parameter_handler function
_get_invalid_parameter_handler function
a176da0e-38ca-4d99-92bb-b0e2b8072f53

_get_invalid_parameter_handler, _get_thread_local_invalid_parameter_handler

Gets the function that is called when the CRT detects an invalid argument.

Syntax

_invalid_parameter_handler _get_invalid_parameter_handler(void);
_invalid_parameter_handler _get_thread_local_invalid_parameter_handler(void);

Return value

A pointer to the currently set invalid parameter handler function, or a null pointer if none has been set.

Remarks

The _get_invalid_parameter_handler function gets the currently set global invalid parameter handler. It returns a null pointer if no global invalid parameter handler was set. Similarly, the _get_thread_local_invalid_parameter_handler gets the current thread-local invalid parameter handler of the thread it's called on, or a null pointer if no handler was set. For information about how to set global and thread-local invalid parameter handlers, see _set_invalid_parameter_handler, _set_thread_local_invalid_parameter_handler.

The returned invalid parameter handler function pointer has the following type:

typedef void (__cdecl* _invalid_parameter_handler)(
    wchar_t const*,
    wchar_t const*,
    wchar_t const*,
    unsigned int,
    uintptr_t
    );

For details on the invalid parameter handler, see the prototype in _set_invalid_parameter_handler, _set_thread_local_invalid_parameter_handler.

By default, this function's global state is scoped to the application. To change this behavior, see Global state in the CRT.

Requirements

Routine Required header
_get_invalid_parameter_handler, _get_thread_local_invalid_parameter_handler C: <stdlib.h>

C++: <cstdlib> or <stdlib.h>

The _get_invalid_parameter_handler and _get_thread_local_invalid_parameter_handler functions are Microsoft-specific. For compatibility information, see Compatibility.

See also

_set_invalid_parameter_handler, _set_thread_local_invalid_parameter_handler
Security-enhanced versions of CRT functions