ReactOS  0.4.13-dev-698-g77671f0
safecrt.h File Reference
#include <errno.h>
Include dependency graph for safecrt.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define MSVCRT_INVALID_PMT(x, err)   (*_errno() = (err), _invalid_parameter(NULL, NULL, NULL, 0, 0))
 
#define MSVCRT_CHECK_PMT_ERR(x, err)   ((x) || (MSVCRT_INVALID_PMT( 0, (err) ), 0))
 
#define MSVCRT_CHECK_PMT(x)   MSVCRT_CHECK_PMT_ERR((x), EINVAL)
 

Functions

void _invalid_parameter (const wchar_t *expression, const wchar_t *function, const wchar_t *file, unsigned int line, uintptr_t pReserved)
 

Variables

void__pInvalidArgHandler
 

Macro Definition Documentation

◆ MSVCRT_CHECK_PMT

#define MSVCRT_CHECK_PMT (   x)    MSVCRT_CHECK_PMT_ERR((x), EINVAL)

Definition at line 16 of file safecrt.h.

◆ MSVCRT_CHECK_PMT_ERR

#define MSVCRT_CHECK_PMT_ERR (   x,
  err 
)    ((x) || (MSVCRT_INVALID_PMT( 0, (err) ), 0))

Definition at line 15 of file safecrt.h.

◆ MSVCRT_INVALID_PMT

#define MSVCRT_INVALID_PMT (   x,
  err 
)    (*_errno() = (err), _invalid_parameter(NULL, NULL, NULL, 0, 0))

Definition at line 14 of file safecrt.h.

Function Documentation

◆ _invalid_parameter()

void _invalid_parameter ( const wchar_t expression,
const wchar_t function,
const wchar_t file,
unsigned int  line,
uintptr_t  pReserved 
)

Definition at line 137 of file errno.c.

139 {
141  else
142  {
143  ERR( "%s:%u %s: %s %lx\n", debugstr_w(file), line, debugstr_w(func), debugstr_w(expr), arg );
144 #if _MSVCR_VER > 0 // FIXME: possible improvement: use a global variable in the DLL
146 #endif
147  }
148 }
GLenum func
Definition: glext.h:6028
#define EXCEPTION_NONCONTINUABLE
Definition: rtltypes.h:150
Definition: query.h:86
static _invalid_parameter_handler invalid_parameter_handler
Definition: errno.c:14
#define debugstr_w
Definition: kernel32.h:32
smooth NULL
Definition: ftsmooth.c:416
Definition: parser.c:48
#define ERR(fmt,...)
Definition: debug.h:109
VOID WINAPI RaiseException(IN DWORD dwExceptionCode, IN DWORD dwExceptionFlags, IN DWORD nNumberOfArguments, IN CONST ULONG_PTR *lpArguments OPTIONAL)
Definition: except.c:693
#define STATUS_INVALID_CRUNTIME_PARAMETER
Definition: ntstatus.h:945
Definition: fci.c:126

Referenced by _fsopen(), _tasctime_s(), localtime_s(), and rand_s().

Variable Documentation

◆ __pInvalidArgHandler

void* __pInvalidArgHandler