Frees physical memory associated with the calling thread's virtual address space.
DWORD FreeRtMemory(
PVOID pAddress, // location of memory to be freed within calling thread's virtual segment
);
pAddressThe virtual memory at the address referenced by pAddress is freed, up to the end of the allocation.
If the value of pAddress was originally returned from a call to AllocateRtMemory, the operation also frees all contiguous physical memory that is found at address, even if the contiguous block begins before offset. In other words, FreeRtMemory deletes all memory previously allocated from a single call to AllocateRtMemory.
If the physical memory pointed to by offset was mapped by a previous call to MapRtPhysicalMemory or MapRtPhysicalMemoryEx or MapRtSharedMemory, no physical memory is deallocated.
-1E_OK 0x0000E_NOT_ALLOCATED 0x00F2E_BAD_ADDR 0x800FpAddress is invalid. One of these conditions exist:
pAddress is outside the calling thread's virtual address space.| Versions | Defined in | Include | Link to |
|---|---|---|---|
| INtime 3.0 | intime/rt/include/rtbase.h | rt.h | rt.lib |