Microsoft Internet Security and Acceleration Server 2004 SDK |
The AllocMemoryPerRequest callback function is used to allocate memory (from the process heap to a buffer) per request. Any memory allocated by using this function will automatically be freed by the ISA Server Web proxy at the end of the request (after the SF_NOTIFY_END_OF_REQUEST notification) even if the session continues. For more information on the types of event notifications that are sent to Web filters, see Event Notifications.
If the memory cannot be allocated, this function returns NULL.
The AllocMemoryPerRequest callback function is declared as:
VOID * WINAPI * AllocMemoryPerRequest( struct _HTTP_FILTER_CONTEXT* pfc, DWORD cbSize, DWORD dwReserved );
The AllocMemoryPerRequest function is called through a pointer that is a member of the WPX_FILTER_CONTEXT structure. To get a pointer to the WPX_FILTER_CONTEXT structure for calling the AllocMemoryPerRequest function, use the TO_WPX_FILTER_CONTEXT macro as follows:
WPX_FILTER_CONTEXT* pwfc = TO_WPX_FILTER_CONTEXT(pfc); if (pwfc != NULL) { ... }
Server: Requires Windows Server 2003 or
Windows 2000.
Version: Requires Internet Security and Acceleration
Server 2004.
Header: Declared in Wpxhttpfilt.h.