Commit a3f6bb82 authored by Ove Kaaven's avatar Ove Kaaven Committed by Alexandre Julliard

Implemented "dereference" pointer flag.

Added NdrClearOutParameters stub.
parent 571bc879
...@@ -561,7 +561,10 @@ void WINAPI PointerMarshall(PMIDL_STUB_MESSAGE pStubMsg, ...@@ -561,7 +561,10 @@ void WINAPI PointerMarshall(PMIDL_STUB_MESSAGE pStubMsg,
pFormat += 2; pFormat += 2;
if (attr & RPC_FC_P_SIMPLEPOINTER) desc = pFormat; if (attr & RPC_FC_P_SIMPLEPOINTER) desc = pFormat;
else desc = pFormat + *(SHORT*)pFormat; else desc = pFormat + *(SHORT*)pFormat;
if (attr & RPC_FC_P_DEREF) FIXME("deref?\n"); if (attr & RPC_FC_P_DEREF) {
Pointer = *(unsigned char**)Pointer;
TRACE("deref => %p\n", Pointer);
}
*(LPVOID*)Buffer = 0; *(LPVOID*)Buffer = 0;
...@@ -597,7 +600,10 @@ void WINAPI PointerUnmarshall(PMIDL_STUB_MESSAGE pStubMsg, ...@@ -597,7 +600,10 @@ void WINAPI PointerUnmarshall(PMIDL_STUB_MESSAGE pStubMsg,
pFormat += 2; pFormat += 2;
if (attr & RPC_FC_P_SIMPLEPOINTER) desc = pFormat; if (attr & RPC_FC_P_SIMPLEPOINTER) desc = pFormat;
else desc = pFormat + *(SHORT*)pFormat; else desc = pFormat + *(SHORT*)pFormat;
if (attr & RPC_FC_P_DEREF) FIXME("deref?\n"); if (attr & RPC_FC_P_DEREF) {
pPointer = *(unsigned char***)pPointer;
TRACE("deref => %p\n", pPointer);
}
switch (type) { switch (type) {
case RPC_FC_RP: /* ref pointer (always non-null) */ case RPC_FC_RP: /* ref pointer (always non-null) */
...@@ -630,7 +636,10 @@ void WINAPI PointerBufferSize(PMIDL_STUB_MESSAGE pStubMsg, ...@@ -630,7 +636,10 @@ void WINAPI PointerBufferSize(PMIDL_STUB_MESSAGE pStubMsg,
pFormat += 2; pFormat += 2;
if (attr & RPC_FC_P_SIMPLEPOINTER) desc = pFormat; if (attr & RPC_FC_P_SIMPLEPOINTER) desc = pFormat;
else desc = pFormat + *(SHORT*)pFormat; else desc = pFormat + *(SHORT*)pFormat;
if (attr & RPC_FC_P_DEREF) FIXME("deref?\n"); if (attr & RPC_FC_P_DEREF) {
Pointer = *(unsigned char**)Pointer;
TRACE("deref => %p\n", Pointer);
}
switch (type) { switch (type) {
case RPC_FC_RP: /* ref pointer (always non-null) */ case RPC_FC_RP: /* ref pointer (always non-null) */
...@@ -660,7 +669,9 @@ unsigned long WINAPI PointerMemorySize(PMIDL_STUB_MESSAGE pStubMsg, ...@@ -660,7 +669,9 @@ unsigned long WINAPI PointerMemorySize(PMIDL_STUB_MESSAGE pStubMsg,
pFormat += 2; pFormat += 2;
if (attr & RPC_FC_P_SIMPLEPOINTER) desc = pFormat; if (attr & RPC_FC_P_SIMPLEPOINTER) desc = pFormat;
else desc = pFormat + *(SHORT*)pFormat; else desc = pFormat + *(SHORT*)pFormat;
if (attr & RPC_FC_P_DEREF) FIXME("deref?\n"); if (attr & RPC_FC_P_DEREF) {
TRACE("deref\n");
}
switch (type) { switch (type) {
case RPC_FC_RP: /* ref pointer (always non-null) */ case RPC_FC_RP: /* ref pointer (always non-null) */
...@@ -693,7 +704,10 @@ void WINAPI PointerFree(PMIDL_STUB_MESSAGE pStubMsg, ...@@ -693,7 +704,10 @@ void WINAPI PointerFree(PMIDL_STUB_MESSAGE pStubMsg,
pFormat += 2; pFormat += 2;
if (attr & RPC_FC_P_SIMPLEPOINTER) desc = pFormat; if (attr & RPC_FC_P_SIMPLEPOINTER) desc = pFormat;
else desc = pFormat + *(SHORT*)pFormat; else desc = pFormat + *(SHORT*)pFormat;
if (attr & RPC_FC_P_DEREF) FIXME("deref?\n"); if (attr & RPC_FC_P_DEREF) {
Pointer = *(unsigned char**)Pointer;
TRACE("deref => %p\n", Pointer);
}
if (!Pointer) return; if (!Pointer) return;
...@@ -717,6 +731,8 @@ void WINAPI PointerFree(PMIDL_STUB_MESSAGE pStubMsg, ...@@ -717,6 +731,8 @@ void WINAPI PointerFree(PMIDL_STUB_MESSAGE pStubMsg,
case RPC_FC_C_WSTRING: case RPC_FC_C_WSTRING:
if (pStubMsg->ReuseBuffer) goto notfree; if (pStubMsg->ReuseBuffer) goto notfree;
break; break;
case RPC_FC_IP:
goto notfree;
} }
if (attr & RPC_FC_P_ONSTACK) { if (attr & RPC_FC_P_ONSTACK) {
...@@ -2070,6 +2086,16 @@ void WINAPI NdrUserMarshalFree(PMIDL_STUB_MESSAGE pStubMsg, ...@@ -2070,6 +2086,16 @@ void WINAPI NdrUserMarshalFree(PMIDL_STUB_MESSAGE pStubMsg,
} }
/*********************************************************************** /***********************************************************************
* NdrClearOutParameters [RPCRT4.@]
*/
void WINAPI NdrClearOutParameters(PMIDL_STUB_MESSAGE pStubMsg,
PFORMAT_STRING pFormat,
void *ArgAddr)
{
FIXME("(%p,%p,%p): stub\n", pStubMsg, pFormat, ArgAddr);
}
/***********************************************************************
* NdrConvert [RPCRT4.@] * NdrConvert [RPCRT4.@]
*/ */
void WINAPI NdrConvert( PMIDL_STUB_MESSAGE pStubMsg, PFORMAT_STRING pFormat ) void WINAPI NdrConvert( PMIDL_STUB_MESSAGE pStubMsg, PFORMAT_STRING pFormat )
......
...@@ -225,7 +225,7 @@ ...@@ -225,7 +225,7 @@
@ stdcall NdrAllocate(ptr long) @ stdcall NdrAllocate(ptr long)
@ stub NdrAsyncClientCall @ stub NdrAsyncClientCall
@ stub NdrAsyncServerCall @ stub NdrAsyncServerCall
@ stub NdrClearOutParameters @ stdcall NdrClearOutParameters(ptr ptr ptr)
@ stub NdrClientCall @ stub NdrClientCall
@ varargs NdrClientCall2(ptr ptr) @ varargs NdrClientCall2(ptr ptr)
@ stub NdrClientInitialize @ stub NdrClientInitialize
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment