rpcrt4: Set pStubMsg->BufferMark in NdrConformantVaryingArrayUnmarshall and NdrVaryingArrayUnmarshall.

pStubMsg->BufferMark should always be set before
EmbeddedPointerUnmarshall is called and these functions didn't
previously do so.
This commit is contained in:
Rob Shearman 2007-12-22 01:39:56 +00:00 committed by Alexandre Julliard
parent 33df0a7605
commit 64d1e2d8e3
1 changed files with 2 additions and 0 deletions

View File

@ -2885,6 +2885,7 @@ unsigned char* WINAPI NdrConformantVaryingArrayUnmarshall( PMIDL_STUB_MESSAGE pS
if (!*ppMemory || fMustAlloc) if (!*ppMemory || fMustAlloc)
*ppMemory = NdrAllocate(pStubMsg, memsize); *ppMemory = NdrAllocate(pStubMsg, memsize);
pStubMsg->BufferMark = pStubMsg->Buffer;
safe_copy_from_buffer(pStubMsg, *ppMemory + pStubMsg->Offset, bufsize); safe_copy_from_buffer(pStubMsg, *ppMemory + pStubMsg->Offset, bufsize);
EmbeddedPointerUnmarshall(pStubMsg, *ppMemory, *ppMemory, pFormat, TRUE /* FIXME */); EmbeddedPointerUnmarshall(pStubMsg, *ppMemory, *ppMemory, pFormat, TRUE /* FIXME */);
@ -4515,6 +4516,7 @@ unsigned char * WINAPI NdrVaryingArrayUnmarshall(PMIDL_STUB_MESSAGE pStubMsg,
if (!*ppMemory || fMustAlloc) if (!*ppMemory || fMustAlloc)
*ppMemory = NdrAllocate(pStubMsg, size); *ppMemory = NdrAllocate(pStubMsg, size);
pStubMsg->BufferMark = pStubMsg->Buffer;
safe_copy_from_buffer(pStubMsg, *ppMemory + pStubMsg->Offset, bufsize); safe_copy_from_buffer(pStubMsg, *ppMemory + pStubMsg->Offset, bufsize);
EmbeddedPointerUnmarshall(pStubMsg, *ppMemory, *ppMemory, pFormat, TRUE /* FIXME */); EmbeddedPointerUnmarshall(pStubMsg, *ppMemory, *ppMemory, pFormat, TRUE /* FIXME */);