Log: Ove Kaaven <ovek@transgaming.com> Added semi-stub for NdrProxyErrorHandler. Fixed a case of potential stack trashing. Index: dlls/rpcrt4/ndr_midl.c =================================================================== RCS file: /home/wine/wine/dlls/rpcrt4/ndr_midl.c,v retrieving revision 1.12 diff -u -r1.12 ndr_midl.c --- dlls/rpcrt4/ndr_midl.c 31 Jan 2003 03:22:53 -0000 1.12 +++ dlls/rpcrt4/ndr_midl.c 20 May 2003 15:06:34 -0000 @@ -122,6 +122,15 @@ } /*********************************************************************** + * NdrProxyErrorHandler [RPCRT4.@] + */ +HRESULT WINAPI NdrProxyErrorHandler(DWORD dwExceptionCode) +{ + FIXME("(0x%08lx): semi-stub\n", dwExceptionCode); + return MAKE_HRESULT(SEVERITY_ERROR, FACILITY_RPC, RPC_S_CALL_FAILED); +} + +/*********************************************************************** * NdrStubInitialize [RPCRT4.@] */ void WINAPI NdrStubInitialize(PRPC_MESSAGE pRpcMsg, @@ -162,7 +171,9 @@ assert( pRpcMessage && pStubMsg && pStubDesc ); memset(pRpcMessage, 0, sizeof(RPC_MESSAGE)); - memset(pStubMsg, 0, sizeof(MIDL_STUB_MESSAGE)); + + /* not everyone allocates stack space for w2kReserved */ + memset(pStubMsg, 0, sizeof(*pStubMsg) - sizeof(pStubMsg->w2kReserved)); pStubMsg->ReuseBuffer = FALSE; pStubMsg->IsClient = TRUE; @@ -185,7 +196,8 @@ assert( pRpcMsg && pStubMsg && pStubDesc ); - memset(pStubMsg, 0, sizeof(MIDL_STUB_MESSAGE)); + /* not everyone allocates stack space for w2kReserved */ + memset(pStubMsg, 0, sizeof(*pStubMsg) - sizeof(pStubMsg->w2kReserved)); pStubMsg->ReuseBuffer = TRUE; pStubMsg->IsClient = FALSE; Index: dlls/rpcrt4/rpcrt4.spec =================================================================== RCS file: /home/wine/wine/dlls/rpcrt4/rpcrt4.spec,v retrieving revision 1.44 diff -u -r1.44 rpcrt4.spec --- dlls/rpcrt4/rpcrt4.spec 26 Apr 2003 02:12:14 -0000 1.44 +++ dlls/rpcrt4/rpcrt4.spec 20 May 2003 15:06:34 -0000 @@ -285,7 +285,7 @@ @ stub NdrPipeSendReceive @ stub NdrPipesDone @ stub NdrPipesInitialize -@ stub NdrProxyErrorHandler +@ stdcall NdrProxyErrorHandler(long) @ stdcall NdrProxyFreeBuffer(ptr ptr) @ stdcall NdrProxyGetBuffer(ptr ptr) @ stdcall NdrProxyInitialize(ptr ptr ptr ptr long)