Unlock the range of process address space already allocated
#include <sys/mman.h> int munlock(const void * addr, size_t len);
Use the -l c option to qcc to link against this library. This library is usually included automatically.
The munlock() function unlocks the specified range of address space, which was locked by a call to mlock() or mlockall(). Memory locks don't stack; the memory is unlocked, no matter how many times the same process locked it.
|The full POSIX implementation for this function was added in the QNX Neutrino Core OS 6.3.2.|
The munlock() function doesn't affect those pages that have been mapped and locked into the address spaces of other processes.
POSIX 1003.1 MLR
mlock(), mlockall(), munlockall()
“Locking memory” in the Process Manager chapter of the System Architecture guide