When my MFC DLL is loaded a class is instantiated in dllmain. How do I free the resources allocated for this when the DLL is unloaded or its process completes? Will this be done automatically by the system? I am using Visual Studio 2008. Thanks.
When my MFC DLL is loaded a class is instantiated in dllmain . How
Share
in you dll main function just handle a case for the DLL_PROCESS_DETACH.
Keep in mind that some things are not possible inside of DllMain(), so you want to keep whatever yo do there very quick and simple.