Obtains the debug heap's current state and stores it in an application-supplied _CrtMemState structure (debug version only).
void _CrtMemCheckpoint ( _CrtMemState * _State );
_State
_CrtMemCheckpoint creates a snapshot of the debug heap's current state at any given moment, which other heap state functions to help detect memory leaks and other problems. When _DEBUG is not defined, preprocessing removes calls to _CrtMemState.
The application must pass a pointer to a previously allocated instance of the _CrtMemState structure, defined in CRTDBG.H, in the _State
parameter. If _CrtMemCheckpoint encounters an error during the checkpoint creation, the function generates a _CRT_WARN debug report that describes the problem.
For more information about heap state functions and the _CrtMemState structure, see Heap State Reporting Functions. For information about how memory blocks are allocated, initialized, and managed in the debug version of the base heap, see Memory Management and the Debug Heap.
None.
Versions | Defined in | Include | Link to |
---|---|---|---|
INtime 3.13 | intime/rt/include/crtdbg.h | crtdbg.h | clib.lib |