RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
System.SysFreeMem Function

Frees the memory pointed to by a specified pointer.

Pascal
function SysFreeMem(P: Pointer): Integer;
C++
int SysFreeMem(void * P);

When implementing a custom memory manager, use SysFreeMem to free the memory pointed to by the P parameter.

Note: On Windows, the System unit provides a limited implementation of SysFreeMem. If the custom memory manager needs to support reference counting and objects that can be shared between processes, use the implementation of SysFreeMem provided by the ShareMem unit. When used, ShareMem must be the first unit in the project file, to enforce a consistent memory management model.
Note: On Linux, the System unit provides an implementation of SysFreeMem that supports reference counting and shared objects. The ShareMem unit is not provided for Linux.
 

Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!