http://bugs.winehq.org/show_bug.cgi?id=20711
--- Comment #12 from Markus mst@collogia.de 2010-03-25 07:23:56 --- To make it short.
the application produces the following call sequence:
- LoadLibrary(dinput8.dll) - First reference to this library - DirectInput8Create() - This will nail a second reference to dinput8.dll due to CoCreateInstance - compobj will store a separated link to dinput8.DllCanUnloadNow()
- game runs.
- FreeLibrary(Handle_To_Dinput8) - destroy first reference to dinput8.dll - FreeLibrary(Handle_To_Dinput8) - This will destroy the last reference to dinput8.dll - dinput8.dll will be unloaded - CoUninitialize - Wants to do its own cleanup of libraries. - Therefore calls stored link of dinput8.DllCanUnloadNow()
This fails as the library is already unloaded from memory.
Best regards.