Retrieves a pointer to the default OLE task memory allocator (which supports the system implementation of the IMalloc interface) so applications can call its methods to manage memory.
HRESULT CoGetMalloc(
DWORD dwMemContext, |
//Indicates if memory is private or shared |
LPMALLOC * ppMalloc |
//Indirect pointer to memory allocator |
); |
Parameters
Return Values
This function supports the standard return values E_INVALIDARG and E_OUTOFMEMORY, as well as the following:
Remarks
The pointer to the IMalloc interface pointer received through the ppMalloc parameter cannot be used from a remote process&emdash;each process must have its own allocator.
See Also