#include <nitro/os.h>
void OS_ClearHeap( OSArenaId id, OSHeapHandle heap, void* start, void* end );
id | Arena ID of the arena that includes the heap being cleared |
heap | Heap handler for the heap being cleared |
start | Starting address of heap region |
end | Ending address of address of heap region (+1) |
None.
This function clears and initializes an existing heap.
All memory blocks secured in heap get destroyed. Specify the heap region using start and end. Be careful when initializing the heap, because if there is an isolated region of heap due to the use of OS_AddToHeap()
, that region will not be initialized. Moreover, upon initialization, that region will be removed from a part. Caution should be exercised when initializing the heap.
11/08/2004 Initial Version