AllocMem callback function
Applies to: desktop apps only
The AllocMem callback function is used to allocate memory from the process heap to a buffer. Any memory allocated by using this callback function will automatically be freed by the Forefront TMG Web proxy after the session ends (as indicated by the SF_NOTIFY_END_OF_NET_SESSION notification). If the memory cannot be allocated, this callback function returns NULL. For more information about the types of event notifications that are sent to Web filters, see Event Notifications.
The AllocMem callback function is declared as:
VOID* WINAPI AllocMem( _In_ struct _HTTP_FILTER_CONTEXT *pfc, _In_ DWORD cbSize, _In_ DWORD dwReserved );
Pointer to the HTTP_FILTER_CONTEXT data structure that is associated with the current, active HTTP session. Pass the filter context in this parameter.
Indicates the size of the buffer to be allocated, in bytes.
Reserved for use by the server.
This callback function does not return a value.
Minimum supported client
Minimum supported server
|Windows Server 2008 R2, Windows Server 2008 with SP2 (64-bit only)|
|Forefront Threat Management Gateway (TMG) 2010|
Build date: 7/12/2010