http://bugs.winehq.org/show_bug.cgi?id=15381
Summary: CoFreeUnusedLibraries will crash COM server or cause 0x800703E6/I_RpcReceive error 0x3e6 Product: Wine Version: 1.0.0 Platform: Other OS/Version: other Status: UNCONFIRMED Severity: normal Priority: P2 Component: ole32 AssignedTo: wine-bugs@winehq.org ReportedBy: dmda@yandex.ru
Created an attachment (id=16230) --> (http://bugs.winehq.org/attachment.cgi?id=16230) demo illustrating the problem
if CoFreeUnusedLibraries is called by COM server, it will break RPC channcel and lead to the errors
Attached is client/server code that demonstrates the problem. If you comment out CoFreeUnusedLibraries call, it will start to work.
Steps: -comple all 3 projects in the Workspace (Debug target is the only appropriate for the sake of demo) -make sure server and proxy are registered by running testserver.exe -RegServer, regsvr32 testserverPS.dll -run testproject.exe (the client)
Expected behaviour: 1. it will show server's message "CServer is created", click ok 2. it will show client's message "press OK when ready", click ok 3. it will show server's message passed by the client "Hello world!", click ok 4. it will show client's message "call succeeded" and client will exit 5. after roughly 6sec it will show that the server is unloaded/
Actual behaviour: 1. it will show server's message "CServer is created", click ok 2. it will show client's message "press OK when ready", click ok 3. it will show server's message passed by the client "Hello world!", click ok 4. it will dump out trouble in the console and show client's message "call failed"
You may call CoFreeUnusedLibraries anywhere in the appartment and it will break RPC on the server side. In some cases it will crash whole the server, like in the demo.
Tested environment: Fedora Core 8, 32bit, x86, wine 1.0 installed through the updates