http://bugs.winehq.org/show_bug.cgi?id=14465
Summary: NdrClientCall2 is unaware of comm_status and fault_status variables Product: Wine Version: CVS/GIT Platform: Other OS/Version: other Status: UNCONFIRMED Severity: critical Priority: P2 Component: rpc AssignedTo: wine-bugs@winehq.org ReportedBy: winesku@googlemail.com
Created an attachment (id=14783) --> (http://bugs.winehq.org/attachment.cgi?id=14783) Test project (VS2005) of a simple RPC client/server to repro the problem
Rpc clients that specify variables or the return value as a comm_status or fault_status variable normally do not guard their RPC call with a SEH try-except clause. After all, using comm_status or fault_status variables is usually done, because with these variables, SEH try-except can be omitted, as any exception from the client side or server side part of the call is transformed into an error value that is assigned to the comm or fault status variable. However, the current implementation of NdrClientCall2 unconditionally raises exceptions, which an RPC client using comm_status and fault_status variables is not prepared or expected to handle. As a result, such RPC clients crash immediately if any error occurs during the course of an RPC call. Find attached a VS2005 project of a simple RPC client and server that can call a variety of RPCs with different comm and fault status behaviour on client and server side, that can be used to reproduce the problem. Start the server using
rpcsrv.exe portnumber
Start the client interactively and choose the RPC variant of choice.
http://bugs.winehq.org/show_bug.cgi?id=14465
--- Comment #1 from Stefan Kuhr winesku@googlemail.com 2008-07-13 09:18:21 --- Created an attachment (id=14784) --> (http://bugs.winehq.org/attachment.cgi?id=14784) Compiled debug and release binaries for the test project
Binaries have been linked statically, so no VC8 runtime should be required to get them running
http://bugs.winehq.org/show_bug.cgi?id=14465
--- Comment #2 from Stefan Kuhr winesku@googlemail.com 2008-07-13 09:23:15 --- Created an attachment (id=14785) --> (http://bugs.winehq.org/attachment.cgi?id=14785) Patch for proper determination of comm_status and fault_status variables
Code that determines the addresses of the comm_status and fault_status variables. Note that this code has been written before I started debugging the XP implementation of NdrClientCall2, so it is not affected by the outcome of the discussion "How do I write an exception filter?" on the wine devel list. This patch could be the starting point for someone who is allowed to add comm and fault status functionality to NdrClientCall2.
http://bugs.winehq.org/show_bug.cgi?id=14465
Vitaliy Margolen vitaliy@kievinfo.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Severity|critical |major OS/Version|other |Linux
http://bugs.winehq.org/show_bug.cgi?id=14465
Austin English austinenglish@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Version|CVS/GIT |unspecified
--- Comment #3 from Austin English austinenglish@gmail.com 2009-01-20 02:39:30 --- Removing deprecated CVS/GIT version tag. Please retest in current git. If the bug is still present in today's wine, but was not present in some earlier version of wine, please update version field to earliest known version of wine that had the bug. Thanks!
http://bugs.winehq.org/show_bug.cgi?id=14465
--- Comment #4 from Andrew Nguyen arethusa26@gmail.com 2009-07-21 13:33:47 --- With 1.1.26, the RPC server aborts with:
"Assertion failed!
Program: ...arethusa\Download\kaiblinbins\debug\rpcsrv.exe File: c:\applic\kaiblin\rpcsrv\rpcsrv.cpp Line: 759
Expression: __ASSERT failed for RPC_S_OK==dwResult"
http://bugs.winehq.org/show_bug.cgi?id=14465
--- Comment #5 from Stefan Kuhr winesku@googlemail.com 2009-07-21 15:49:57 --- Andrew,
did you run the RPC server under Wine? I never dared to do that, it is not what this bug is all about. comm_status and fault_status are things that an RPC-client should handle properly, the server doesn't even know how the client handles comm_status and fault_status or if it handles it at all. If you want to reproduce the problems with the missing handling of comm_status and fault_status, then you should run the server on a windows box and the client under Wine. I am sorry if this wasn't clear enough from my bug description.
http://bugs.winehq.org/show_bug.cgi?id=14465
--- Comment #6 from Andrew Nguyen arethusa26@gmail.com 2009-07-22 04:47:57 --- Indeed, my prior attempt was running the RPC server on Wine, my apologies. I certainly do see the issues remain on wine-1.1.26-82-gda86ab7.
http://bugs.winehq.org/show_bug.cgi?id=14465
--- Comment #7 from Rob Shearman robertshearman@gmail.com 2009-11-16 08:44:31 --- Patch sent that should fix this: http://www.winehq.org/pipermail/wine-patches/2009-November/081444.html
Please retest.
http://bugs.winehq.org/show_bug.cgi?id=14465
Rob Shearman robertshearman@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |RESOLVED Resolution| |FIXED
--- Comment #8 from Rob Shearman robertshearman@gmail.com 2009-12-05 04:52:25 --- Assuming fixed.
http://bugs.winehq.org/show_bug.cgi?id=14465
--- Comment #9 from Stefan Kuhr winesku@googlemail.com 2009-12-05 08:48:05 --- My apologies for coming back so late for a comment. Yes, everything looks good so far with this fix. Thanks for fixing this bug.
http://bugs.winehq.org/show_bug.cgi?id=14465
Alexandre Julliard julliard@winehq.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #10 from Alexandre Julliard julliard@winehq.org 2009-12-18 13:07:08 --- Closing bugs fixed in 1.1.35.