INtime SDK Help
heap_dump
INtime SDK v6 > About INtime > Other system libraries > Heaps and memory pools > C/C++ Runtime heap > heap_dump

Dumps heap statistics and lists to the console or to a file.

int heap_dump(
    DWORD flags, 
    const char * fname
);

Parameters

flags
Valid values include:
MPOOL_DUMP_STATS Dump statistics.
MPOOL_DUMP_BLKHDR Dump block headers.
MPOOL_DUMP_BUFHDR Dump buffer headers.
MPOOL_DUMP_BUFFER Dump buffer contents.
MPOOL_DUMP_ALLOCED Dump the allocated buffer list.
MPOOL_DUMP_FREED Dump the freed buffer list.
fname
The name of file to dump to. If the file cannot be created or fname is NULL, output is directed to the console.

Remarks

Use this call only in a low-priority context as it may slow your system. The heap is locked for the duration of the call.

Return Values

0 (zero)
Success.
Less than 0 (zero)
Failure. The function sets errno to one of these values:
EEXIST The heap is deleted.
EINVAL The heap is not a valid MPOOL or an internal error was detected.

Requirements

Versions Defined in Include Link to
INtime 4.0 intime/rt/include/heap.h heap.h clib.lib
   
See Also