Rob Shearman : rpcrt4:
Translate STATUS_ACCESS_VIOLATION exceptions caught whilst executing
the stub function to ERROR_NOACCESS to prevent confusing
exceptions occurring in the client .
Alexandre Julliard
julliard at wine.codeweavers.com
Tue Jun 26 07:11:46 CDT 2007
Module: wine
Branch: master
Commit: 2de3d31a7a2362f754d3313d35383a8714da4d29
URL: http://source.winehq.org/git/wine.git/?a=commit;h=2de3d31a7a2362f754d3313d35383a8714da4d29
Author: Rob Shearman <rob at codeweavers.com>
Date: Mon Jun 25 14:24:23 2007 +0100
rpcrt4: Translate STATUS_ACCESS_VIOLATION exceptions caught whilst executing the stub function to ERROR_NOACCESS to prevent confusing exceptions occurring in the client.
---
dlls/rpcrt4/rpc_server.c | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)
diff --git a/dlls/rpcrt4/rpc_server.c b/dlls/rpcrt4/rpc_server.c
index 712a18b..0250902 100644
--- a/dlls/rpcrt4/rpc_server.c
+++ b/dlls/rpcrt4/rpc_server.c
@@ -235,6 +235,7 @@ static void RPCRT4_process_packet(RpcConnection* conn, RpcPktHdr* hdr, RPC_MESSA
sif = RPCRT4_find_interface(object_uuid, &conn->ActiveInterface, TRUE);
if (!sif) {
+ WARN("interface %s no longer registered, returning fault packet\n", debugstr_guid(&conn->ActiveInterface.SyntaxGUID));
response = RPCRT4_BuildFaultHeader(NDR_LOCAL_DATA_REPRESENTATION,
RPC_S_UNKNOWN_IF);
@@ -278,7 +279,10 @@ static void RPCRT4_process_packet(RpcConnection* conn, RpcPktHdr* hdr, RPC_MESSA
msg->RpcFlags |= WINE_RPCFLAG_EXCEPTION;
msg->BufferLength = sizeof(DWORD);
I_RpcGetBuffer(msg);
- *(DWORD*)msg->Buffer = GetExceptionCode();
+ if (GetExceptionCode() == STATUS_ACCESS_VIOLATION)
+ *(DWORD*)msg->Buffer = ERROR_NOACCESS;
+ else
+ *(DWORD*)msg->Buffer = GetExceptionCode();
} __ENDTRY
/* send response packet */
More information about the wine-cvs
mailing list