Rob Shearman : rpcrt4: Allocate a context handle if a NULL GUID is being unmarshalled.
Alexandre Julliard
julliard at winehq.org
Mon Jan 14 09:33:16 CST 2008
Module: wine
Branch: master
Commit: 576c9dc6fa227ba9536117f062703cf6e4c15bc0
URL: http://source.winehq.org/git/wine.git/?a=commit;h=576c9dc6fa227ba9536117f062703cf6e4c15bc0
Author: Rob Shearman <rob at codeweavers.com>
Date: Sun Jan 13 20:52:25 2008 +0000
rpcrt4: Allocate a context handle if a NULL GUID is being unmarshalled.
---
dlls/rpcrt4/ndr_contexthandle.c | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/dlls/rpcrt4/ndr_contexthandle.c b/dlls/rpcrt4/ndr_contexthandle.c
index 7334bf6..8ed8f66 100644
--- a/dlls/rpcrt4/ndr_contexthandle.c
+++ b/dlls/rpcrt4/ndr_contexthandle.c
@@ -320,6 +320,7 @@ NDR_SCONTEXT WINAPI NDRSContextUnmarshall2(RPC_BINDING_HANDLE hBinding,
RpcBinding *binding = hBinding;
NDR_SCONTEXT SContext;
RPC_STATUS status;
+ const ndr_context_handle *context_ndr = pBuff;
TRACE("(%p %p %08x %p %u)\n",
hBinding, pBuff, DataRepresentation, CtxGuard, Flags);
@@ -330,12 +331,12 @@ NDR_SCONTEXT WINAPI NDRSContextUnmarshall2(RPC_BINDING_HANDLE hBinding,
if (Flags & RPC_CONTEXT_HANDLE_FLAGS)
FIXME("unimplemented flags: 0x%x\n", Flags & RPC_CONTEXT_HANDLE_FLAGS);
- if (!pBuff)
+ if (!pBuff || (!context_ndr->attributes &&
+ UuidIsNil((UUID *)&context_ndr->uuid, &status)))
status = RpcServerAssoc_AllocateContextHandle(binding->Assoc, CtxGuard,
&SContext);
else
{
- const ndr_context_handle *context_ndr = pBuff;
if (context_ndr->attributes)
{
ERR("non-null attributes 0x%x\n", context_ndr->attributes);
More information about the wine-cvs
mailing list