void __RPC_USER midl_user_free(void __RPC_FAR * pBuffer);
Both client application and server application must implement the midl_user_free function, unless you are compiling in OSF-compatibility (/osf) mode. The midl_user_free function must be able to free all storage allocated by midl_user_allocate.
Applications and stubs call midl_user_free when dealing with allocated objects. For example:
For example, the RPC Win32 sample program that displays "Hello, world" implements midl_user_free in terms of the C function free:
void __RPC_USER midl_user_free(void __RPC_FAR * p)
{
free(p);
}
Note If the Rpcss package is enabled (for example, as the result of using the enable_allocate attribute), RpcSmFree can be used to free memory. See Rpcss Memory Management Model for more information.