STLdoc
STLdocumentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
crtdbg.h
Go to the documentation of this file.
1 /***
2 *crtdbg.h - Supports debugging features of the C runtime library.
3 *
4 * Copyright (c) Microsoft Corporation. All rights reserved.
5 *
6 *Purpose:
7 * Support CRT debugging features.
8 *
9 * [Public]
10 *
11 ****/
12 
13 #pragma once
14 
15 #include <crtdefs.h>
16 
17 #ifndef _INC_CRTDBG
18 #define _INC_CRTDBG
19 
20 #pragma pack(push,_CRT_PACKING)
21 #pragma push_macro("new")
22 #undef new
23 
24 /* Define NULL here since we depend on it and for back-compat
25 */
26 #ifndef NULL
27 #ifdef __cplusplus
28 #define NULL 0
29 #else /* __cplusplus */
30 #define NULL ((void *)0)
31 #endif /* __cplusplus */
32 #endif /* NULL */
33 
34 #ifdef __cplusplus
35 extern "C" {
36 #endif /* __cplusplus */
37 
38  /****************************************************************************
39  *
40  * Debug Reporting
41  *
42  ***************************************************************************/
43 
44 typedef void *_HFILE; /* file handle pointer */
45 
46 #define _CRT_WARN 0
47 #define _CRT_ERROR 1
48 #define _CRT_ASSERT 2
49 #define _CRT_ERRCNT 3
50 
51 #define _CRTDBG_MODE_FILE 0x1
52 #define _CRTDBG_MODE_DEBUG 0x2
53 #define _CRTDBG_MODE_WNDW 0x4
54 #define _CRTDBG_REPORT_MODE -1
55 
56 #if defined (_M_IX86)
57 #define _CRTDBG_INVALID_HFILE ((_HFILE)-1)
58 #define _CRTDBG_HFILE_ERROR ((_HFILE)-2)
59 #define _CRTDBG_FILE_STDOUT ((_HFILE)-4)
60 #define _CRTDBG_FILE_STDERR ((_HFILE)-5)
61 #define _CRTDBG_REPORT_FILE ((_HFILE)-6)
62 #else /* defined (_M_IX86) */
63 #define _CRTDBG_INVALID_HFILE ((_HFILE)(__int64)-1)
64 #define _CRTDBG_HFILE_ERROR ((_HFILE)(__int64)-2)
65 #define _CRTDBG_FILE_STDOUT ((_HFILE)(__int64)-4)
66 #define _CRTDBG_FILE_STDERR ((_HFILE)(__int64)-5)
67 #define _CRTDBG_REPORT_FILE ((_HFILE)(__int64)-6)
68 #endif /* defined (_M_IX86) */
69 
70 #if !defined (_M_CEE_PURE)
71 typedef int (__cdecl * _CRT_REPORT_HOOK)(int, char *, int *);
72 typedef int (__cdecl * _CRT_REPORT_HOOKW)(int, wchar_t *, int *);
73 #else /* !defined (_M_CEE_PURE) */
74 typedef int (__clrcall * _CRT_REPORT_HOOK)(int, char *, int *);
75 typedef int (__clrcall * _CRT_REPORT_HOOKW)(int, wchar_t *, int *);
76 #endif /* !defined (_M_CEE_PURE) */
77 
78 #if defined (_M_CEE)
79 typedef int (__clrcall *_CRT_REPORT_HOOK_M)(int, char *, int *);
80 typedef int (__clrcall *_CRT_REPORT_HOOKW_M)(int, wchar_t *, int *);
81 #endif /* defined (_M_CEE) */
82 
83 #define _CRT_RPTHOOK_INSTALL 0
84 #define _CRT_RPTHOOK_REMOVE 1
85 
86  /****************************************************************************
87  *
88  * Heap
89  *
90  ***************************************************************************/
91 
92  /****************************************************************************
93  *
94  * Client-defined allocation hook
95  *
96  ***************************************************************************/
97 
98 #define _HOOK_ALLOC 1
99 #define _HOOK_REALLOC 2
100 #define _HOOK_FREE 3
101 
102 #if !defined (_M_CEE_PURE)
103 typedef int (__cdecl * _CRT_ALLOC_HOOK)(int, void *, size_t, int, long, const unsigned char *, int);
104 #else /* !defined (_M_CEE_PURE) */
105 typedef int (__clrcall * _CRT_ALLOC_HOOK)(int, void *, size_t, int, long, const unsigned char *, int);
106 #endif /* !defined (_M_CEE_PURE) */
107 #if defined (_M_CEE)
108 typedef int (__clrcall * _CRT_ALLOC_HOOK_M)(int, void *, size_t, int, long, const unsigned char *, int);
109 #endif /* defined (_M_CEE) */
110 
111  /****************************************************************************
112  *
113  * Memory management
114  *
115  ***************************************************************************/
116 
117 /*
118  * Bit values for _crtDbgFlag flag:
119  *
120  * These bitflags control debug heap behavior.
121  */
122 
123 #define _CRTDBG_ALLOC_MEM_DF 0x01 /* Turn on debug allocation */
124 #define _CRTDBG_DELAY_FREE_MEM_DF 0x02 /* Don't actually free memory */
125 #define _CRTDBG_CHECK_ALWAYS_DF 0x04 /* Check heap every alloc/dealloc */
126 #define _CRTDBG_RESERVED_DF 0x08 /* Reserved - do not use */
127 #define _CRTDBG_CHECK_CRT_DF 0x10 /* Leak check/diff CRT blocks */
128 #define _CRTDBG_LEAK_CHECK_DF 0x20 /* Leak check at program exit */
129 
130 /*
131  * Some bit values for _crtDbgFlag which correspond to frequencies for checking
132  * the the heap.
133  */
134 #define _CRTDBG_CHECK_EVERY_16_DF 0x00100000 /* check heap every 16 heap ops */
135 #define _CRTDBG_CHECK_EVERY_128_DF 0x00800000 /* check heap every 128 heap ops */
136 #define _CRTDBG_CHECK_EVERY_1024_DF 0x04000000 /* check heap every 1024 heap ops */
137 /*
138 We do not check the heap by default at this point because the cost was too high
139 for some applications. You can still turn this feature on manually.
140 */
141 #define _CRTDBG_CHECK_DEFAULT_DF 0
142 
143 #define _CRTDBG_REPORT_FLAG -1 /* Query bitflag status */
144 
145 #define _BLOCK_TYPE(block) (block & 0xFFFF)
146 #define _BLOCK_SUBTYPE(block) (block >> 16 & 0xFFFF)
147 
148 
149  /****************************************************************************
150  *
151  * Memory state
152  *
153  ***************************************************************************/
154 
155 /* Memory block identification */
156 #define _FREE_BLOCK 0
157 #define _NORMAL_BLOCK 1
158 #define _CRT_BLOCK 2
159 #define _IGNORE_BLOCK 3
160 #define _CLIENT_BLOCK 4
161 #define _MAX_BLOCKS 5
162 
163 #if !defined (_M_CEE_PURE)
164 typedef void (__cdecl * _CRT_DUMP_CLIENT)(void *, size_t);
165 #else /* !defined (_M_CEE_PURE) */
166 typedef void (__clrcall * _CRT_DUMP_CLIENT)(void *, size_t);
167 #endif /* !defined (_M_CEE_PURE) */
168 #if defined (_M_CEE)
169 typedef void (__clrcall * _CRT_DUMP_CLIENT_M)(void *, size_t);
170 #endif /* defined (_M_CEE) */
171 
172 struct _CrtMemBlockHeader;
173 typedef struct _CrtMemState
174 {
175  struct _CrtMemBlockHeader * pBlockHeader;
179  size_t lTotalCount;
180 } _CrtMemState;
181 
182 
183  /****************************************************************************
184  *
185  * Declarations, prototype and function-like macros
186  *
187  ***************************************************************************/
188 
189 /* _STATIC_ASSERT is for enforcing boolean/integral conditions at compile time.
190  Since it is purely a compile-time mechanism that generates no code, the check
191  is left in even if _DEBUG is not defined. */
192 
193 #ifndef _STATIC_ASSERT
194 #define _STATIC_ASSERT(expr) typedef char __static_assert_t[ (expr) ]
195 #endif /* _STATIC_ASSERT */
196 
197 #ifndef _DEBUG
198 
199  /****************************************************************************
200  *
201  * Debug OFF
202  * Debug OFF
203  * Debug OFF
204  *
205  ***************************************************************************/
206 
207 /* We allow our basic _ASSERT macros to be overridden by pre-existing definitions.
208  This is not the ideal mechanism, but is helpful in some scenarios and helps avoid
209  multiple definition problems */
210 
211 #ifndef _ASSERT
212 #define _ASSERT(expr) ((void)0)
213 #endif /* _ASSERT */
214 
215 #ifndef _ASSERTE
216 #define _ASSERTE(expr) ((void)0)
217 #endif /* _ASSERTE */
218 
219 #ifndef _ASSERT_EXPR
220 #define _ASSERT_EXPR(expr, expr_str) ((void)0)
221 #endif /* _ASSERT_EXPR */
222 
223 #ifndef _ASSERT_BASE
224 #define _ASSERT_BASE _ASSERT_EXPR
225 #endif /* _ASSERT_BASE */
226 
227 #define _RPT0(rptno, msg)
228 #define _RPTW0(rptno, msg)
229 
230 #define _RPT1(rptno, msg, arg1)
231 #define _RPTW1(rptno, msg, arg1)
232 
233 #define _RPT2(rptno, msg, arg1, arg2)
234 #define _RPTW2(rptno, msg, arg1, arg2)
235 
236 #define _RPT3(rptno, msg, arg1, arg2, arg3)
237 #define _RPTW3(rptno, msg, arg1, arg2, arg3)
238 
239 #define _RPT4(rptno, msg, arg1, arg2, arg3, arg4)
240 #define _RPTW4(rptno, msg, arg1, arg2, arg3, arg4)
241 
242 #define _RPT5(rptno, msg, arg1, arg2, arg3, arg4, arg5)
243 #define _RPTW5(rptno, msg, arg1, arg2, arg3, arg4, arg5)
244 
245 
246 #define _RPTF0(rptno, msg)
247 #define _RPTFW0(rptno, msg)
248 
249 #define _RPTF1(rptno, msg, arg1)
250 #define _RPTFW1(rptno, msg, arg1)
251 
252 #define _RPTF2(rptno, msg, arg1, arg2)
253 #define _RPTFW2(rptno, msg, arg1, arg2)
254 
255 #define _RPTF3(rptno, msg, arg1, arg2, arg3)
256 #define _RPTFW3(rptno, msg, arg1, arg2, arg3)
257 
258 #define _RPTF4(rptno, msg, arg1, arg2, arg3, arg4)
259 #define _RPTFW4(rptno, msg, arg1, arg2, arg3, arg4)
260 
261 #define _RPTF5(rptno, msg, arg1, arg2, arg3, arg4, arg5)
262 #define _RPTFW5(rptno, msg, arg1, arg2, arg3, arg4, arg5)
263 
264 #define _malloc_dbg(s, t, f, l) malloc(s)
265 #define _calloc_dbg(c, s, t, f, l) calloc(c, s)
266 #define _realloc_dbg(p, s, t, f, l) realloc(p, s)
267 #define _recalloc_dbg(p, c, s, t, f, l) _recalloc(p, c, s)
268 #define _expand_dbg(p, s, t, f, l) _expand(p, s)
269 #define _free_dbg(p, t) free(p)
270 #define _msize_dbg(p, t) _msize(p)
271 
272 #define _aligned_msize_dbg(p, a, o) _aligned_msize(p, a, o)
273 #define _aligned_malloc_dbg(s, a, f, l) _aligned_malloc(s, a)
274 #define _aligned_realloc_dbg(p, s, a, f, l) _aligned_realloc(p, s, a)
275 #define _aligned_recalloc_dbg(p, c, s, a, f, l) _aligned_recalloc(p, c, s, a)
276 #define _aligned_free_dbg(p) _aligned_free(p)
277 #define _aligned_offset_malloc_dbg(s, a, o, f, l) _aligned_offset_malloc(s, a, o)
278 #define _aligned_offset_realloc_dbg(p, s, a, o, f, l) _aligned_offset_realloc(p, s, a, o)
279 #define _aligned_offset_recalloc_dbg(p, c, s, a, o, f, l) _aligned_offset_recalloc(p, c, s, a, o)
280 
281 #define _malloca_dbg(s, t, f, l) _malloca(s)
282 #define _freea_dbg(p, t) _freea(p)
283 
284 #define _strdup_dbg(s, t, f, l) _strdup(s)
285 #define _wcsdup_dbg(s, t, f, l) _wcsdup(s)
286 #define _mbsdup_dbg(s, t, f, l) _mbsdup(s)
287 #define _tempnam_dbg(s1, s2, t, f, l) _tempnam(s1, s2)
288 #define _wtempnam_dbg(s1, s2, t, f, l) _wtempnam(s1, s2)
289 #define _fullpath_dbg(s1, s2, le, t, f, l) _fullpath(s1, s2, le)
290 #define _wfullpath_dbg(s1, s2, le, t, f, l) _wfullpath(s1, s2, le)
291 #define _getcwd_dbg(s, le, t, f, l) _getcwd(s, le)
292 #define _wgetcwd_dbg(s, le, t, f, l) _wgetcwd(s, le)
293 #define _getdcwd_dbg(d, s, le, t, f, l) _getdcwd(d, s, le)
294 #define _wgetdcwd_dbg(d, s, le, t, f, l) _wgetdcwd(d, s, le)
295 #define _getdcwd_lk_dbg(d, s, le, t, f, l) _getdcwd(d, s, le)
296 #define _wgetdcwd_lk_dbg(d, s, le, t, f, l) _wgetdcwd(d, s, le)
297 #define _dupenv_s_dbg(ps1, size, s2, t, f, l) _dupenv_s(ps1, size, s2)
298 #define _wdupenv_s_dbg(ps1, size, s2, t, f, l) _wdupenv_s(ps1, size, s2)
299 
300 #define _CrtSetReportHook(f) ((_CRT_REPORT_HOOK)0)
301 #define _CrtGetReportHook() ((_CRT_REPORT_HOOK)0)
302 #define _CrtSetReportHook2(t, f) ((int)0)
303 #define _CrtSetReportHookW2(t, f) ((int)0)
304 #define _CrtSetReportMode(t, f) ((int)0)
305 #define _CrtSetReportFile(t, f) ((_HFILE)0)
306 
307 #define _CrtDbgBreak() ((void)0)
308 
309 #define _CrtSetBreakAlloc(a) ((long)0)
310 
311 #define _CrtSetAllocHook(f) ((_CRT_ALLOC_HOOK)0)
312 #define _CrtGetAllocHook() ((_CRT_ALLOC_HOOK)0)
313 
314 #define _CrtCheckMemory() ((int)1)
315 #define _CrtSetDbgFlag(f) ((int)0)
316 #define _CrtDoForAllClientObjects(f, c) ((void)0)
317 #define _CrtIsValidPointer(p, n, r) ((int)1)
318 #define _CrtIsValidHeapPointer(p) ((int)1)
319 #define _CrtIsMemoryBlock(p, t, r, f, l) ((int)1)
320 #define _CrtReportBlockType(p) ((int)-1)
321 
322 #define _CrtSetDumpClient(f) ((_CRT_DUMP_CLIENT)0)
323 #define _CrtGetDumpClient() ((_CRT_DUMP_CLIENT)0)
324 
325 #define _CrtMemCheckpoint(s) ((void)0)
326 #define _CrtMemDifference(s1, s2, s3) ((int)0)
327 #define _CrtMemDumpAllObjectsSince(s) ((void)0)
328 #define _CrtMemDumpStatistics(s) ((void)0)
329 #define _CrtDumpMemoryLeaks() ((int)0)
330 #define _CrtSetDebugFillThreshold(t) ((size_t)0)
331 
332 #define _CrtSetCheckCount(f) ((int)0)
333 #define _CrtGetCheckCount() ((int)0)
334 
335 #else /* _DEBUG */
336 
337 
338  /****************************************************************************
339  *
340  * Debug ON
341  * Debug ON
342  * Debug ON
343  *
344  ***************************************************************************/
345 
346 
347 /* Define _MRTIMP */
348 
349 #ifndef _MRTIMP
350 #if defined(MRTDLL) && defined(_CRTBLD)
351 #define _MRTIMP __declspec(dllexport)
352 #else /* defined(MRTDLL) && defined(_CRTBLD) */
353 #define _MRTIMP __declspec(dllimport)
354 #endif /* defined(MRTDLL) && defined(_CRTBLD) */
355 #endif /* _MRTIMP */
356 
357 /* Define _CRTIMP */
358 
359 #ifndef _CRTIMP
360 #if defined(CRTDLL) && defined(_CRTBLD)
361 #define _CRTIMP __declspec(dllexport)
362 #else /* defined(CRTDLL) && defined(_CRTBLD) */
363 #ifdef _DLL
364 #define _CRTIMP __declspec(dllimport)
365 #else /* _DLL */
366 #define _CRTIMP
367 #endif /* _DLL */
368 #endif /* defined(CRTDLL) && defined(_CRTBLD) */
369 #endif /* _CRTIMP */
370 
371  /****************************************************************************
372  *
373  * Debug Reporting
374  *
375  ***************************************************************************/
376 
377 #ifdef _CRTBLD
378 #if defined (_DLL) && defined (_M_IX86)
379 /* Retained for compatibility with VC++ 5.0 and earlier versions */
380 _CRTIMP long * __cdecl __p__crtAssertBusy(void);
381 #endif /* defined (_DLL) && defined (_M_IX86) */
382 #endif /* _CRTBLD */
383 
384 #if !defined (_M_CEE_PURE)
385 _CRTIMP extern long _crtAssertBusy;
386 #endif /* !defined (_M_CEE_PURE) */
387 
388 #if !defined (_M_CEE_PURE)
390  void
391  );
392 #endif /* !defined (_M_CEE_PURE) */
393 
394 /* _CrtSetReportHook[[W]2]:
395  * For IJW, we need 2 versions: 1 for clrcall and one for cdecl.
396  * For pure and native, we just need clrcall and cdecl, respectively.
397  */
398 #if !defined (_M_CEE_PURE)
400  _In_opt_ _CRT_REPORT_HOOK _PFnNewHook
401  );
402 
403 _CRTIMP int __cdecl _CrtSetReportHook2(
404  _In_ int _Mode,
405  _In_opt_ _CRT_REPORT_HOOK _PFnNewHook
406  );
407 
408 _CRTIMP int __cdecl _CrtSetReportHookW2(
409  _In_ int _Mode,
410  _In_opt_ _CRT_REPORT_HOOKW _PFnNewHook
411  );
412 #endif /* !defined (_M_CEE_PURE) */
413 
414 _CRTIMP int __cdecl _CrtSetReportMode(
415  _In_ int _ReportType,
416  _In_ int _ReportMode
417  );
418 
419 _CRTIMP _HFILE __cdecl _CrtSetReportFile(
420  _In_ int _ReportType,
421  _In_opt_ _HFILE _ReportFile
422  );
423 
424 _CRTIMP int __cdecl _CrtDbgReport(
425  _In_ int _ReportType,
426  _In_opt_z_ const char * _Filename,
427  _In_ int _Linenumber,
428  _In_opt_z_ const char * _ModuleName,
429  _In_opt_z_ const char * _Format,
430  ...);
431 
432 _CRTIMP size_t __cdecl _CrtSetDebugFillThreshold(
433  _In_ size_t _NewDebugFillThreshold
434  );
435 
436 #if !defined (_NATIVE_WCHAR_T_DEFINED) && defined (_M_CEE_PURE)
437 extern "C++"
438 #endif /* !defined (_NATIVE_WCHAR_T_DEFINED) && defined (_M_CEE_PURE) */
439 _CRTIMP int __cdecl _CrtDbgReportW(
440  _In_ int _ReportType,
441  _In_opt_z_ const wchar_t * _Filename,
442  _In_ int _LineNumber,
443  _In_opt_z_ const wchar_t * _ModuleName,
444  _In_opt_z_ const wchar_t * _Format,
445  ...);
446 
447 /* Asserts */
448 /* We use !! below to ensure that any overloaded operators used to evaluate expr do not end up at operator || */
449 #define _ASSERT_EXPR(expr, msg) \
450  (void) ((!!(expr)) || \
451  (1 != _CrtDbgReportW(_CRT_ASSERT, _CRT_WIDE(__FILE__), __LINE__, NULL, L"%s", msg)) || \
452  (_CrtDbgBreak(), 0))
453 
454 #ifndef _ASSERT
455 #define _ASSERT(expr) _ASSERT_EXPR((expr), NULL)
456 #endif /* _ASSERT */
457 
458 #ifndef _ASSERTE
459 #define _ASSERTE(expr) _ASSERT_EXPR((expr), _CRT_WIDE(#expr))
460 #endif /* _ASSERTE */
461 
462 /*
463 We retain _ASSERT_BASE solely for backwards compatibility with those who used it even though they
464 should not have done so since it was not documented.
465 */
466 #ifndef _ASSERT_BASE
467 #define _ASSERT_BASE _ASSERT_EXPR
468 #endif /* _ASSERT_BASE */
469 
470 /* Reports with no file/line info */
471 
472 #define _RPT_BASE(args) \
473  (void) ((1 != _CrtDbgReport args) || \
474  (_CrtDbgBreak(), 0))
475 
476 #define _RPT_BASE_W(args) \
477  (void) ((1 != _CrtDbgReportW args) || \
478  (_CrtDbgBreak(), 0))
479 
480 #define _RPT0(rptno, msg) \
481  _RPT_BASE((rptno, NULL, 0, NULL, "%s", msg))
482 
483 #define _RPTW0(rptno, msg) \
484  _RPT_BASE_W((rptno, NULL, 0, NULL, L"%s", msg))
485 
486 #define _RPT1(rptno, msg, arg1) \
487  _RPT_BASE((rptno, NULL, 0, NULL, msg, arg1))
488 
489 #define _RPTW1(rptno, msg, arg1) \
490  _RPT_BASE_W((rptno, NULL, 0, NULL, msg, arg1))
491 
492 #define _RPT2(rptno, msg, arg1, arg2) \
493  _RPT_BASE((rptno, NULL, 0, NULL, msg, arg1, arg2))
494 
495 #define _RPTW2(rptno, msg, arg1, arg2) \
496  _RPT_BASE_W((rptno, NULL, 0, NULL, msg, arg1, arg2))
497 
498 #define _RPT3(rptno, msg, arg1, arg2, arg3) \
499  _RPT_BASE((rptno, NULL, 0, NULL, msg, arg1, arg2, arg3))
500 
501 #define _RPTW3(rptno, msg, arg1, arg2, arg3) \
502  _RPT_BASE_W((rptno, NULL, 0, NULL, msg, arg1, arg2, arg3))
503 
504 #define _RPT4(rptno, msg, arg1, arg2, arg3, arg4) \
505  _RPT_BASE((rptno, NULL, 0, NULL, msg, arg1, arg2, arg3, arg4))
506 
507 #define _RPTW4(rptno, msg, arg1, arg2, arg3, arg4) \
508  _RPT_BASE_W((rptno, NULL, 0, NULL, msg, arg1, arg2, arg3, arg4))
509 
510 #define _RPT5(rptno, msg, arg1, arg2, arg3, arg4, arg5) \
511  _RPT_BASE((rptno, NULL, 0, NULL, msg, arg1, arg2, arg3, arg4, arg5))
512 
513 #define _RPTW5(rptno, msg, arg1, arg2, arg3, arg4, arg5) \
514  _RPT_BASE_W((rptno, NULL, 0, NULL, msg, arg1, arg2, arg3, arg4, arg5))
515 
516 /* Reports with file/line info */
517 
518 #define _RPTF0(rptno, msg) \
519  _RPT_BASE((rptno, __FILE__, __LINE__, NULL, "%s", msg))
520 
521 #define _RPTFW0(rptno, msg) \
522  _RPT_BASE_W((rptno, _CRT_WIDE(__FILE__), __LINE__, NULL, L"%s", msg))
523 
524 #define _RPTF1(rptno, msg, arg1) \
525  _RPT_BASE((rptno, __FILE__, __LINE__, NULL, msg, arg1))
526 
527 #define _RPTFW1(rptno, msg, arg1) \
528  _RPT_BASE_W((rptno, _CRT_WIDE(__FILE__), __LINE__, NULL, msg, arg1))
529 
530 #define _RPTF2(rptno, msg, arg1, arg2) \
531  _RPT_BASE((rptno, __FILE__, __LINE__, NULL, msg, arg1, arg2))
532 
533 #define _RPTFW2(rptno, msg, arg1, arg2) \
534  _RPT_BASE_W((rptno, _CRT_WIDE(__FILE__), __LINE__, NULL, msg, arg1, arg2))
535 
536 #define _RPTF3(rptno, msg, arg1, arg2, arg3) \
537  _RPT_BASE((rptno, __FILE__, __LINE__, NULL, msg, arg1, arg2, arg3))
538 
539 #define _RPTFW3(rptno, msg, arg1, arg2, arg3) \
540  _RPT_BASE_W((rptno, _CRT_WIDE(__FILE__), __LINE__, NULL, msg, arg1, arg2, arg3))
541 
542 #define _RPTF4(rptno, msg, arg1, arg2, arg3, arg4) \
543  _RPT_BASE((rptno, __FILE__, __LINE__, NULL, msg, arg1, arg2, arg3, arg4))
544 
545 #define _RPTFW4(rptno, msg, arg1, arg2, arg3, arg4) \
546  _RPT_BASE_W((rptno, _CRT_WIDE(__FILE__), __LINE__, NULL, msg, arg1, arg2, arg3, arg4))
547 
548 #define _RPTF5(rptno, msg, arg1, arg2, arg3, arg4, arg5) \
549  _RPT_BASE((rptno, __FILE__, __LINE__, NULL, msg, arg1, arg2, arg3, arg4, arg5))
550 
551 #define _RPTFW5(rptno, msg, arg1, arg2, arg3, arg4, arg5) \
552  _RPT_BASE_W((rptno, _CRT_WIDE(__FILE__), __LINE__, NULL, msg, arg1, arg2, arg3, arg4, arg5))
553 
554 #if !defined (_CRT_PORTABLE)
555 #define _CrtDbgBreak() __debugbreak()
556 #else /* !defined (_CRT_PORTABLE) */
557 _CRTIMP void __cdecl _CrtDbgBreak(
558  void
559  );
560 #endif /* !defined (_CRT_PORTABLE) */
561 
562  /****************************************************************************
563  *
564  * Heap routines
565  *
566  ***************************************************************************/
567 
568 #ifdef _CRTDBG_MAP_ALLOC
569 
570 #define malloc(s) _malloc_dbg(s, _NORMAL_BLOCK, __FILE__, __LINE__)
571 #define calloc(c, s) _calloc_dbg(c, s, _NORMAL_BLOCK, __FILE__, __LINE__)
572 #define realloc(p, s) _realloc_dbg(p, s, _NORMAL_BLOCK, __FILE__, __LINE__)
573 #define _recalloc(p, c, s) _recalloc_dbg(p, c, s, _NORMAL_BLOCK, __FILE__, __LINE__)
574 #define _expand(p, s) _expand_dbg(p, s, _NORMAL_BLOCK, __FILE__, __LINE__)
575 #define free(p) _free_dbg(p, _NORMAL_BLOCK)
576 #define _msize(p) _msize_dbg(p, _NORMAL_BLOCK)
577 #define _aligned_msize(p, a, o) _aligned_msize_dbg(p, a, o)
578 #define _aligned_malloc(s, a) _aligned_malloc_dbg(s, a, __FILE__, __LINE__)
579 #define _aligned_realloc(p, s, a) _aligned_realloc_dbg(p, s, a, __FILE__, __LINE__)
580 #define _aligned_recalloc(p, c, s, a) _aligned_recalloc_dbg(p, c, s, a, __FILE__, __LINE__)
581 #define _aligned_offset_malloc(s, a, o) _aligned_offset_malloc_dbg(s, a, o, __FILE__, __LINE__)
582 #define _aligned_offset_realloc(p, s, a, o) _aligned_offset_realloc_dbg(p, s, a, o, __FILE__, __LINE__)
583 #define _aligned_offset_recalloc(p, c, s, a, o) _aligned_offset_recalloc_dbg(p, c, s, a, o, __FILE__, __LINE__)
584 #define _aligned_free(p) _aligned_free_dbg(p)
585 
586 #define _malloca(s) _malloca_dbg(s, _NORMAL_BLOCK, __FILE__, __LINE__)
587 #define _freea(p) _freea_dbg(p, _NORMAL_BLOCK)
588 
589 #define _strdup(s) _strdup_dbg(s, _NORMAL_BLOCK, __FILE__, __LINE__)
590 #define _wcsdup(s) _wcsdup_dbg(s, _NORMAL_BLOCK, __FILE__, __LINE__)
591 #define _mbsdup(s) _strdup_dbg(s, _NORMAL_BLOCK, __FILE__, __LINE__)
592 #define _tempnam(s1, s2) _tempnam_dbg(s1, s2, _NORMAL_BLOCK, __FILE__, __LINE__)
593 #define _wtempnam(s1, s2) _wtempnam_dbg(s1, s2, _NORMAL_BLOCK, __FILE__, __LINE__)
594 #define _fullpath(s1, s2, le) _fullpath_dbg(s1, s2, le, _NORMAL_BLOCK, __FILE__, __LINE__)
595 #define _wfullpath(s1, s2, le) _wfullpath_dbg(s1, s2, le, _NORMAL_BLOCK, __FILE__, __LINE__)
596 #define _getcwd(s, le) _getcwd_dbg(s, le, _NORMAL_BLOCK, __FILE__, __LINE__)
597 #define _wgetcwd(s, le) _wgetcwd_dbg(s, le, _NORMAL_BLOCK, __FILE__, __LINE__)
598 #define _getdcwd(d, s, le) _getdcwd_dbg(d, s, le, _NORMAL_BLOCK, __FILE__, __LINE__)
599 #define _wgetdcwd(d, s, le) _wgetdcwd_dbg(d, s, le, _NORMAL_BLOCK, __FILE__, __LINE__)
600 #define _dupenv_s(ps1, size, s2) _dupenv_s_dbg(ps1, size, s2, _NORMAL_BLOCK, __FILE__, __LINE__)
601 #define _wdupenv_s(ps1, size, s2) _wdupenv_s_dbg(ps1, size, s2, _NORMAL_BLOCK, __FILE__, __LINE__)
602 
603 #if !__STDC__
604 #define strdup(s) _strdup_dbg(s, _NORMAL_BLOCK, __FILE__, __LINE__)
605 #define wcsdup(s) _wcsdup_dbg(s, _NORMAL_BLOCK, __FILE__, __LINE__)
606 #define tempnam(s1, s2) _tempnam_dbg(s1, s2, _NORMAL_BLOCK, __FILE__, __LINE__)
607 #define getcwd(s, le) _getcwd_dbg(s, le, _NORMAL_BLOCK, __FILE__, __LINE__)
608 #endif /* !__STDC__ */
609 
610 
611 #endif /* _CRTDBG_MAP_ALLOC */
612 
613 #ifdef _CRTBLD
614 #if defined (_DLL) && defined (_M_IX86)
615 /* Retained for compatibility with VC++ 5.0 and earlier versions */
616 _CRTIMP long * __cdecl __p__crtBreakAlloc(void);
617 #endif /* defined (_DLL) && defined (_M_IX86) */
618 #endif /* _CRTBLD */
619 
620 #if !defined (_M_CEE_PURE)
621 _CRTIMP extern long _crtBreakAlloc; /* Break on this allocation */
622 #endif /* !defined (_M_CEE_PURE) */
623 
624 _CRTIMP long __cdecl _CrtSetBreakAlloc(
625  _In_ long _BreakAlloc
626  );
627 
628 /*
629  * Prototypes for malloc, free, realloc, etc are in malloc.h
630  */
631 
633  _In_ size_t _Size,
634  _In_ int _BlockType,
635  _In_opt_z_ const char * _Filename,
636  _In_ int _LineNumber
637  );
638 
640  _In_ size_t _Count,
641  _In_ size_t _Size,
642  _In_ int _BlockType,
643  _In_opt_z_ const char * _Filename,
644  _In_ int _LineNumber
645  );
646 
647 _Success_(return!=0)
649  _Pre_maybenull_ _Post_invalid_ void * _Memory,
650  _In_ size_t _NewSize,
651  _In_ int _BlockType,
652  _In_opt_z_ const char * _Filename,
653  _In_ int _LineNumber
654  );
655 
656 _Success_(return!=0)
658 (
659  _Pre_maybenull_ _Post_invalid_ void * _Memory,
660  _In_ size_t _NumOfElements,
661  _In_ size_t _SizeOfElements,
662  _In_ int _BlockType,
663  _In_opt_z_ const char * _Filename,
664  _In_ int _LineNumber
665 );
666 
668  _Pre_notnull_ void * _Memory,
669  _In_ size_t _NewSize,
670  _In_ int _BlockType,
671  _In_opt_z_ const char * _Filename,
672  _In_ int _LineNumber
673  );
674 
675 _CRTIMP void __cdecl _free_dbg(
676  _Pre_maybenull_ _Post_invalid_ void * _Memory,
677  _In_ int _BlockType
678  );
679 
680 _CRTIMP size_t __cdecl _msize_dbg (
681  _Pre_notnull_ void * _Memory,
682  _In_ int _BlockType
683  );
684 
685 _CRTIMP size_t __cdecl _aligned_msize_dbg (
686  _Pre_notnull_ void * _Memory,
687  _In_ size_t _Alignment,
688  _In_ size_t _Offset
689  );
690 
692  _In_ size_t _Size,
693  _In_ size_t _Alignment,
694  _In_opt_z_ const char * _Filename,
695  _In_ int _LineNumber
696  );
697 
698 _Success_(return!=0)
700  _Pre_maybenull_ _Post_invalid_ void * _Memory,
701  _In_ size_t _NewSize,
702  _In_ size_t _Alignment,
703  _In_opt_z_ const char * _Filename,
704  _In_ int _LineNumber
705  );
706 
707 _Success_(return!=0)
708 _Check_return_ _Ret_maybenull_ _Post_writable_byte_size_(_NumOfElements*_SizeOfElements) _CRTIMP void * __cdecl _aligned_recalloc_dbg
709 (
710  _Pre_maybenull_ _Post_invalid_ void * _Memory,
711  _In_ size_t _NumOfElements,
712  _In_ size_t _SizeOfElements,
713  _In_ size_t _Alignment,
714  _In_opt_z_ const char * _Filename,
715  _In_ int _LineNumber
716 );
717 
719  _In_ size_t _Size,
720  _In_ size_t _Alignment,
721  _In_ size_t _Offset,
722  _In_opt_z_ const char * _Filename,
723  _In_ int _LineNumber
724  );
725 
726 _Success_(return!=0)
728  _Pre_maybenull_ _Post_invalid_ void * _Memory,
729  _In_ size_t _NewSize,
730  _In_ size_t _Alignment,
731  _In_ size_t _Offset,
732  _In_opt_z_ const char * _Filename,
733  _In_ int _LineNumber
734  );
735 
736 _Success_(return!=0)
738 (
739  _Pre_maybenull_ _Post_invalid_ void * _Memory,
740  _In_ size_t _NumOfElements,
741  _In_ size_t _SizeOfElements,
742  _In_ size_t _Alignment,
743  _In_ size_t _Offset,
744  _In_opt_z_ const char * _Filename,
745  _In_ int _LineNumber
746 );
747 
748 _CRTIMP void __cdecl _aligned_free_dbg(
749  _Pre_maybenull_ _Post_invalid_ void * _Memory
750  );
751 
753  _In_opt_z_ const char * _Str,
754  _In_ int _BlockType,
755  _In_opt_z_ const char * _Filename,
756  _In_ int _LineNumber
757  );
758 
760  _In_opt_z_ const wchar_t * _Str,
761  _In_ int _BlockType,
762  _In_opt_z_ const char * _Filename,
763  _In_ int _LineNumber
764  );
765 
767  _In_opt_z_ const char * _DirName,
768  _In_opt_z_ const char * _FilePrefix,
769  _In_ int _BlockType,
770  _In_opt_z_ const char * _Filename,
771  _In_ int _LineNumber
772  );
773 
775  _In_opt_z_ const wchar_t * _DirName,
776  _In_opt_z_ const wchar_t * _FilePrefix,
777  _In_ int _BlockType,
778  _In_opt_z_ const char * _Filename,
779  _In_ int _LineNumber
780  );
781 
783  _Out_writes_opt_z_(_SizeInBytes) char * _FullPath,
784  _In_z_ const char * _Path,
785  _In_ size_t _SizeInBytes,
786  _In_ int _BlockType,
787  _In_opt_z_ const char * _Filename,
788  _In_ int _LineNumber
789  );
790 
792  _Out_writes_opt_z_(_SizeInWords) wchar_t * _FullPath,
793  _In_z_ const wchar_t * _Path,
794  _In_ size_t _SizeInWords,
795  _In_ int _BlockType,
796  _In_opt_z_ const char * _Filename,
797  _In_ int _LineNumber
798  );
799 
801  _Out_writes_opt_z_(_SizeInBytes) char * _DstBuf,
802  _In_ int _SizeInBytes,
803  _In_ int _BlockType,
804  _In_opt_z_ const char * _Filename,
805  _In_ int _LineNumber
806  );
807 
809  _Out_writes_opt_z_(_SizeInWords) wchar_t * _DstBuf,
810  _In_ int _SizeInWords,
811  _In_ int _BlockType,
812  _In_opt_z_ const char * _Filename,
813  _In_ int _LineNumber
814  );
815 
817  _In_ int _Drive,
818  _Out_writes_opt_z_(_SizeInBytes) char * _DstBuf,
819  _In_ int _SizeInBytes,
820  _In_ int _BlockType,
821  _In_opt_z_ const char * _Filename,
822  _In_ int _LineNumber
823  );
824 
826  _In_ int _Drive,
827  _Out_writes_opt_z_(_SizeInWords) wchar_t * _DstBuf,
828  _In_ int _SizeInWords,
829  _In_ int _BlockType,
830  _In_opt_z_ const char * _Filename,
831  _In_ int _LineNumber
832  );
833 
835  _In_ int _Drive,
836  _Out_writes_opt_z_(_SizeInBytes) char * _DstBuf,
837  _In_ int _SizeInBytes,
838  _In_ int _BlockType,
839  _In_opt_z_ const char * _Filename,
840  _In_ int _LineNumber
841  );
842 
844  _In_ int _Drive,
845  _Out_writes_opt_z_(_SizeInWords) wchar_t * _DstBuf,
846  _In_ int _SizeInWords,
847  _In_ int _BlockType,
848  _In_opt_z_ const char * _Filename,
849  _In_ int _LineNumber
850  );
851 
853  _Outptr_result_buffer_maybenull_(*_PBufferSizeInBytes) _Outptr_result_z_ char ** _PBuffer,
854  _Out_opt_ size_t * _PBufferSizeInBytes,
855  _In_z_ const char * _VarName,
856  _In_ int _BlockType,
857  _In_opt_z_ const char * _Filename,
858  _In_ int _LineNumber
859  );
860 
862  _Outptr_result_buffer_maybenull_(*_PBufferSizeInWords) _Outptr_result_z_ wchar_t ** _PBuffer,
863  _Out_opt_ size_t * _PBufferSizeInWords,
864  _In_z_ const wchar_t * _VarName,
865  _In_ int _BlockType,
866  _In_opt_z_ const char * _Filename,
867  _In_ int _LineNumber
868  );
869 
870 #define _malloca_dbg(s, t, f, l) _malloc_dbg(s, t, f, l)
871 #define _freea_dbg(p, t) _free_dbg(p, t)
872 
873 #if defined (__cplusplus) && defined (_CRTDBG_MAP_ALLOC)
874 namespace std
875 {
877 }
878 #endif /* defined (__cplusplus) && defined (_CRTDBG_MAP_ALLOC) */
879 
880  /****************************************************************************
881  *
882  * Client-defined allocation hook
883  *
884  ***************************************************************************/
885 #if !defined (_M_CEE_PURE)
887 (
888  void
889 );
890 #endif /* !defined (_M_CEE_PURE) */
891 
892 /* _CrtSetAllocHook:
893  * For IJW, we need 2 versions: 1 for clrcall and one for cdecl.
894  * For pure and native, we just need clrcall and cdecl, respectively.
895  */
896 #if !defined (_M_CEE_PURE)
898 (
899  _In_opt_ _CRT_ALLOC_HOOK _PfnNewHook
900 );
901 #endif /* !defined (_M_CEE_PURE) */
902 
903  /****************************************************************************
904  *
905  * Memory management
906  *
907  ***************************************************************************/
908 
909 /*
910  * Bitfield flag that controls CRT heap behavior
911  * Default setting is _CRTDBG_ALLOC_MEM_DF
912  */
913 
914 #ifdef _CRTBLD
915 #if defined (_DLL) && defined (_M_IX86)
916 /* Retained for compatibility with VC++ 5.0 and earlier versions */
917 _CRTIMP int * __cdecl __p__crtDbgFlag(void);
918 #endif /* defined (_DLL) && defined (_M_IX86) */
919 #endif /* _CRTBLD */
920 
921 #if !defined (_M_CEE_PURE)
922 _CRTIMP extern int _crtDbgFlag;
923 #endif /* !defined (_M_CEE_PURE) */
924 
925 _CRTIMP int __cdecl _CrtCheckMemory(
926  void
927  );
928 
929 _CRTIMP int __cdecl _CrtSetDbgFlag(
930  _In_ int _NewFlag
931  );
932 
934  _In_ void (__cdecl *_PFn)(void *, void *),
935  void * _Context
936  );
937 
939  _In_opt_ const void * _Ptr,
940  _In_ unsigned int _Bytes,
941  _In_ int _ReadWrite
942  );
943 
945  _In_opt_ const void * _HeapPtr
946  );
947 
948 _CRTIMP int __cdecl _CrtIsMemoryBlock(
949  _In_opt_ const void * _Memory,
950  _In_ unsigned int _Bytes,
951  _Out_opt_ long * _RequestNumber,
952  _Out_opt_ char ** _Filename,
953  _Out_opt_ int * _LineNumber
954  );
955 
957  _In_opt_ const void * _Memory
958  );
959 
960 
961  /****************************************************************************
962  *
963  * Memory state
964  *
965  ***************************************************************************/
966 
967 #if !defined (_M_CEE_PURE)
969 (
970  void
971 );
972 #endif /* !defined (_M_CEE_PURE) */
973 
974 /* _CrtSetDumpClient:
975  * For IJW, we need 2 versions: 1 for clrcall and one for cdecl.
976  * For pure and native, we just need clrcall and cdecl, respectively.
977  */
978 #if !defined (_M_CEE_PURE)
980 (
981  _In_opt_ _CRT_DUMP_CLIENT _PFnNewDump
982 );
983 #endif /* !defined (_M_CEE_PURE) */
984 
986  _Out_ _CrtMemState * _State
987  );
988 
990  _Out_ _CrtMemState * _State,
991  _In_ const _CrtMemState * _OldState,
992  _In_ const _CrtMemState * _NewState
993  );
994 
996  _In_opt_ const _CrtMemState * _State
997  );
998 
999 _CRTIMP void __cdecl _CrtMemDumpStatistics(
1000  _In_ const _CrtMemState * _State
1001  );
1002 
1003 _CRTIMP int __cdecl _CrtDumpMemoryLeaks(
1004  void
1005  );
1006 
1007 _CRTIMP int __cdecl _CrtSetCheckCount(
1008  _In_ int _CheckCount
1009  );
1010 
1011 _CRTIMP int __cdecl _CrtGetCheckCount(
1012  void
1013  );
1014 
1015 #endif /* _DEBUG */
1016 
1017 #ifdef __cplusplus
1018 }
1019 
1020 #ifndef _MFC_OVERRIDES_NEW
1021 
1022 extern "C++" {
1023 
1024 #ifndef _DEBUG
1025 
1026  /****************************************************************************
1027  *
1028  * Debug OFF
1029  * Debug OFF
1030  * Debug OFF
1031  *
1032  ***************************************************************************/
1033 
1034 
1035 #pragma warning(suppress: 4985)
1036 _Ret_notnull_ _Post_writable_byte_size_(_Size) void * __CRTDECL operator new[](size_t _Size);
1037 
1038 #if !defined (_M_CEE_PURE)
1039 _Ret_notnull_ _Post_writable_byte_size_(_Size) void * __CRTDECL operator new(
1040  size_t _Size,
1041  int,
1042  const char *,
1043  int
1044  );
1045 
1046 #pragma warning(suppress: 4985)
1047 _Ret_notnull_ _Post_writable_byte_size_(_Size) void * __CRTDECL operator new[](
1048  size_t _Size,
1049  int,
1050  const char *,
1051  int
1052  );
1053 
1054 void __CRTDECL operator delete[](void *);
1055 void __CRTDECL operator delete(void * _P, int, const char *, int);
1056 void __CRTDECL operator delete[](void * _P, int, const char *, int);
1057 
1058 #endif /* !defined (_M_CEE_PURE) */
1059 #else /* _DEBUG */
1060 
1061  /****************************************************************************
1062  *
1063  * Debug ON
1064  * Debug ON
1065  * Debug ON
1066  *
1067  ***************************************************************************/
1068 
1069 #pragma warning(suppress: 4985)
1070 _Ret_notnull_ _Post_writable_byte_size_(_Size) void * __CRTDECL operator new[](size_t _Size);
1071 
1072 _Ret_notnull_ _Post_writable_byte_size_(_Size) void * __CRTDECL operator new(
1073  size_t _Size,
1074  int,
1075  const char *,
1076  int
1077  );
1078 
1079 #pragma warning(suppress: 4985)
1080 _Ret_notnull_ _Post_writable_byte_size_(_Size) void * __CRTDECL operator new[](
1081  size_t _Size,
1082  int,
1083  const char *,
1084  int
1085  );
1086 
1087 void __CRTDECL operator delete[](void *);
1088 void __CRTDECL operator delete(void * _P, int, const char *, int);
1089 void __CRTDECL operator delete[](void * _P, int, const char *, int);
1090 
1091 #if defined (_CRTDBG_MAP_ALLOC) && defined (_CRTDBG_MAP_ALLOC_NEW)
1092 /* We keep these inlines for back compatibility only;
1093  * the operator new defined in the debug libraries already calls _malloc_dbg,
1094  * thus enabling the debug heap allocation functionalities.
1095  *
1096  * These inlines do not add any information, due that __FILE__ is expanded
1097  * to "crtdbg.h", which is not very helpful to the user.
1098  *
1099  * The user will need to define _CRTDBG_MAP_ALLOC_NEW in addition to
1100  * _CRTDBG_MAP_ALLOC to enable these inlines.
1101  */
1102 
1103 _Ret_notnull_ _Post_writable_byte_size_(_Size) inline void * __CRTDECL operator new(size_t _Size)
1104  { return ::operator new(_Size, _NORMAL_BLOCK, __FILE__, __LINE__); }
1105 
1106 _Ret_notnull_ _Post_writable_byte_size_(_Size) inline void* __CRTDECL operator new[](size_t _Size)
1107  { return ::operator new[](_Size, _NORMAL_BLOCK, __FILE__, __LINE__); }
1108 
1109 #endif /* defined (_CRTDBG_MAP_ALLOC) && defined (_CRTDBG_MAP_ALLOC_NEW) */
1110 
1111 #endif /* _DEBUG */
1112 
1113 }
1114 
1115 #endif /* _MFC_OVERRIDES_NEW */
1116 
1117 #endif /* __cplusplus */
1118 
1119 #pragma pop_macro("new")
1120 #pragma pack(pop)
1121 
1122 #endif /* _INC_CRTDBG */
#define _Out_
Definition: sal.h:351
_Check_return_opt_ _In_ long _Offset
Definition: io.h:334
#define _tempnam_dbg(s1, s2, t, f, l)
Definition: crtdbg.h:287
#define _MAX_BLOCKS
Definition: crtdbg.h:161
struct _CrtMemState _CrtMemState
#define _Out_opt_
Definition: sal.h:352
int(__cdecl * _CRT_ALLOC_HOOK)(int, void *, size_t, int, long, const unsigned char *, int)
Definition: crtdbg.h:103
#define _CrtCheckMemory()
Definition: crtdbg.h:314
#define _CrtDumpMemoryLeaks()
Definition: crtdbg.h:329
_Check_return_ _In_ int _Mode
Definition: io.h:338
#define _CRTIMP
Definition: crtdefs.h:23
void * _HFILE
Definition: crtdbg.h:44
#define _CrtGetAllocHook()
Definition: crtdbg.h:312
#define _Ret_maybenull_
Definition: sal.h:535
#define _Outptr_result_z_
Definition: sal.h:440
#define _wgetdcwd_lk_dbg(d, s, le, t, f, l)
Definition: crtdbg.h:296
_W64 unsigned int size_t
Definition: crtdefs.h:496
#define _CrtDoForAllClientObjects(f, c)
Definition: crtdbg.h:316
#define _Out_writes_opt_z_(size)
Definition: sal.h:359
size_t lSizes[_MAX_BLOCKS]
Definition: crtdbg.h:177
#define _aligned_free_dbg(p)
Definition: crtdbg.h:276
_CRTIMP _In_opt_z_ const wchar_t _In_opt_z_ const wchar_t unsigned int
Definition: crtdefs.h:642
_In_opt_z_ const char * _FilePrefix
Definition: stdio.h:709
#define _CrtMemCheckpoint(s)
Definition: crtdbg.h:325
#define _getcwd_dbg(s, le, t, f, l)
Definition: crtdbg.h:291
#define _Post_invalid_
Definition: sal.h:701
typedef void(__cdecl *_se_translator_function)(unsigned int
STL namespace.
#define _CrtMemDifference(s1, s2, s3)
Definition: crtdbg.h:326
int(__cdecl * _CRT_REPORT_HOOKW)(int, wchar_t *, int *)
Definition: crtdbg.h:72
#define _CrtSetReportFile(t, f)
Definition: crtdbg.h:305
#define _Outptr_result_buffer_maybenull_(size)
Definition: sal.h:470
#define _aligned_realloc_dbg(p, s, a, f, l)
Definition: crtdbg.h:274
#define _CrtSetBreakAlloc(a)
Definition: crtdbg.h:309
size_t lCounts[_MAX_BLOCKS]
Definition: crtdbg.h:176
#define _CrtMemDumpAllObjectsSince(s)
Definition: crtdbg.h:327
#define _CrtIsMemoryBlock(p, t, r, f, l)
Definition: crtdbg.h:319
_Check_return_ _CRTIMP _Inout_ unsigned int _In_ unsigned int _SizeOfElements
Definition: search.h:112
#define _wfullpath_dbg(s1, s2, le, t, f, l)
Definition: crtdbg.h:290
struct _CrtMemBlockHeader * pBlockHeader
Definition: crtdbg.h:175
#define _aligned_offset_realloc_dbg(p, s, a, o, f, l)
Definition: crtdbg.h:278
#define _aligned_malloc_dbg(s, a, f, l)
Definition: crtdbg.h:273
_CRTIMP _Pre_notnull_ _Post_z_ char * _DstBuf
Definition: stdlib.h:483
#define _aligned_offset_malloc_dbg(s, a, o, f, l)
Definition: crtdbg.h:277
void(__cdecl * _CRT_DUMP_CLIENT)(void *, size_t)
Definition: crtdbg.h:164
#define _CrtIsValidPointer(p, n, r)
Definition: crtdbg.h:317
_Check_return_ _CRTIMP _Inout_ unsigned int * _NumOfElements
Definition: search.h:112
#define _Pre_maybenull_
Definition: sal.h:687
#define _In_opt_z_
Definition: sal.h:320
_In_ _CRT_GUARDOVERFLOW size_t _NewSize
Definition: malloc.h:108
#define _realloc_dbg(p, s, t, f, l)
Definition: crtdbg.h:266
#define _Check_return_
Definition: sal.h:563
#define _In_z_
Definition: sal.h:319
#define _In_
Definition: sal.h:314
#define _CrtIsValidHeapPointer(p)
Definition: crtdbg.h:318
#define _wdupenv_s_dbg(ps1, size, s2, t, f, l)
Definition: crtdbg.h:298
#define _wgetdcwd_dbg(d, s, le, t, f, l)
Definition: crtdbg.h:294
#define _CrtDbgBreak()
Definition: crtdbg.h:307
#define _In_opt_
Definition: sal.h:315
#define _CrtSetAllocHook(f)
Definition: crtdbg.h:311
size_t lTotalCount
Definition: crtdbg.h:179
#define _msize_dbg(p, t)
Definition: crtdbg.h:270
#define _dupenv_s_dbg(ps1, size, s2, t, f, l)
Definition: crtdbg.h:297
#define _CrtGetCheckCount()
Definition: crtdbg.h:333
#define _recalloc_dbg(p, c, s, t, f, l)
Definition: crtdbg.h:267
#define _CrtMemDumpStatistics(s)
Definition: crtdbg.h:328
#define _Ret_maybenull_z_
Definition: sal.h:531
int(__cdecl * _CRT_REPORT_HOOK)(int, char *, int *)
Definition: crtdbg.h:71
#define _free_dbg(p, t)
Definition: crtdbg.h:269
#define _CrtSetReportHook2(t, f)
Definition: crtdbg.h:302
_Pre_maybenull_ _Post_z_ char * _Drive
Definition: stdlib.h:854
Definition: crtdbg.h:173
size_t lHighWaterCount
Definition: crtdbg.h:178
int errno_t
Definition: crtdefs.h:563
#define _CrtSetDumpClient(f)
Definition: crtdbg.h:322
#define _wtempnam_dbg(s1, s2, t, f, l)
Definition: crtdbg.h:288
_In_z_ const char * _Filename
Definition: process.h:211
#define __CRTDECL
Definition: crtdefs.h:622
#define _strdup_dbg(s, t, f, l)
Definition: crtdbg.h:284
#define _expand_dbg(p, s, t, f, l)
Definition: crtdbg.h:268
#define _getdcwd_dbg(d, s, le, t, f, l)
Definition: crtdbg.h:293
#define _calloc_dbg(c, s, t, f, l)
Definition: crtdbg.h:265
#define _getdcwd_lk_dbg(d, s, le, t, f, l)
Definition: crtdbg.h:295
#define _Ret_notnull_
Definition: sal.h:534
#define _Check_return_wat_
Definition: crtdefs.h:2128
#define _CrtGetDumpClient()
Definition: crtdbg.h:323
return(_PAIR_TYPE(_FwdIt)(_First, _First))
_Check_return_ _In_z_ _Scanf_format_string_ const char * _Format
Definition: stdio.h:230
#define _CRT_MANAGED_HEAP_DEPRECATE
Definition: crtdefs.h:341
#define _fullpath_dbg(s1, s2, le, t, f, l)
Definition: crtdbg.h:289
#define _CrtSetReportHook(f)
Definition: crtdbg.h:300
_Diff _Count
Definition: algorithm:1941
#define _NORMAL_BLOCK
Definition: crtdbg.h:157
#define _aligned_offset_recalloc_dbg(p, c, s, a, o, f, l)
Definition: crtdbg.h:279
#define _CrtGetReportHook()
Definition: crtdbg.h:301
#define _wgetcwd_dbg(s, le, t, f, l)
Definition: crtdbg.h:292
#define _wcsdup_dbg(s, t, f, l)
Definition: crtdbg.h:285
#define _Post_writable_byte_size_(size)
Definition: sal.h:658
#define _malloc_dbg(s, t, f, l)
Definition: crtdbg.h:264
#define _aligned_msize_dbg(p, a, o)
Definition: crtdbg.h:272
#define _Success_(expr)
Definition: sal.h:265
#define _CrtSetCheckCount(f)
Definition: crtdbg.h:332
_Check_return_ _In_ long _Size
Definition: io.h:325
#define _CrtReportBlockType(p)
Definition: crtdbg.h:320
#define _Pre_notnull_
Definition: sal.h:686
#define _CrtSetDbgFlag(f)
Definition: crtdbg.h:315
_Check_return_ _Ret_maybenull_z_ _In_ int _SizeInBytes
Definition: direct.h:130
#define _CrtSetReportHookW2(t, f)
Definition: crtdbg.h:303
#define _CrtSetDebugFillThreshold(t)
Definition: crtdbg.h:330
#define _aligned_recalloc_dbg(p, c, s, a, f, l)
Definition: crtdbg.h:275
#define _CrtSetReportMode(t, f)
Definition: crtdbg.h:304
_Check_return_ _Ret_maybenull_ _In_ size_t _Alignment
Definition: malloc.h:112