Microsoft Windows CE 3.0  

CoTaskMemFree

Important:
This is retired content. This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This content may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.

This function frees a block of task memory previously allocated through a call to the CoTaskMemAllocor CoTaskMemReallocfunction.

void CoTaskMemFree(
void
pv
);

Parameter

pv
[in] Void pointer to the memory block to be freed.

Return Values

None.

Remarks

The CoTaskMemFreefunction, using the default OLE allocator, frees a block of memory previously allocated through a call to the CoTaskMemAllocor CoTaskMemReallocfunction.

The number of bytes freed equals the number of bytes that were originally allocated or reallocated. After the call, the memory block pointed to by pvis invalid and can no longer be used.

The pvparameter can be NULL, in which case this method has no effect.

Passing into this function any invalid and, under some circumstances, NULL pointers result in unexpected termination of the application.

Requirements

Runs On Versions Defined in Include Link to
Windows CE OS 2.0 and later Objbase.h    
Note   This API is part of the complete Windows CE OS package as provided by Microsoft. The functionality of a particular platform is determined by the original equipment manufacturer (OEM) and some devices may not support this API.

See Also

CoTaskMemAlloc, CoTaskMemRealloc