HeapDestroy

HeapDestroy destroys the specified heap object. It uncommits and releases all the pages of a private heap object and invalidates the heap handle.

Syntax

Copy
BOOL HeapDestroy(
    [in]    HANDLE hHeap
);

Parameters

[in] hHeap

The heap to be destroyed. This parameter should be a heap handle returned by HeapCreate. A heap handle returned by GetProcessHeap should not be used.

Return Value

If the function succeeds, it returns TRUE. If the function fails, it returns FALSE. Call GetLastError to get extended error information.

Remarks

Processes can call HeapDestroy without first calling HeapFree to free memory allocated from the heap.

Requirements

Minimum supported version Header Library

wRTOS 1.0 SDK

windows.h

wRTOS_rtss.lib

See Also: