summaryrefslogtreecommitdiff
path: root/testprogs/win32/midltests/midltests_marshall.c
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2010-09-28 11:04:59 +0200
committerStefan Metzmacher <metze@samba.org>2010-09-29 01:42:28 +0200
commit115ad6012540338a73abd9de13c6bb4de3a12cf2 (patch)
treeb0eef4839d67d96a382541ad6404fe12cfcf6cfb /testprogs/win32/midltests/midltests_marshall.c
parentcf4e57281b867878521d6f38ec5b0f552c4d2c90 (diff)
downloadsamba-115ad6012540338a73abd9de13c6bb4de3a12cf2.tar.gz
samba-115ad6012540338a73abd9de13c6bb4de3a12cf2.tar.bz2
samba-115ad6012540338a73abd9de13c6bb4de3a12cf2.zip
midltests: add a midltests_tcp.exe tool
This uses a man in the middle approach in order to dump the request and response pdus. It also tests NDR32 and NDR64. metze
Diffstat (limited to 'testprogs/win32/midltests/midltests_marshall.c')
-rw-r--r--testprogs/win32/midltests/midltests_marshall.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/testprogs/win32/midltests/midltests_marshall.c b/testprogs/win32/midltests/midltests_marshall.c
index e772afd03d..f0fc78a71d 100644
--- a/testprogs/win32/midltests/midltests_marshall.c
+++ b/testprogs/win32/midltests/midltests_marshall.c
@@ -30,7 +30,7 @@ static void print_asc(const unsigned char *buf,int len)
printf("%c", isprint(buf[i])?buf[i]:'.');
}
-static void dump_data(const unsigned char *buf1,int len)
+void dump_data(const unsigned char *buf1,int len)
{
const unsigned char *buf = (const unsigned char *)buf1;
int i=0;
@@ -61,6 +61,8 @@ static void dump_data(const unsigned char *buf1,int len)
}
}
+#if _WIN32_WINNT < 0x600
+
void NdrGetBufferMarshall(PMIDL_STUB_MESSAGE stubmsg, unsigned long len, RPC_BINDING_HANDLE hnd)
{
stubmsg->RpcMsg->Buffer = HeapAlloc(GetProcessHeap(), 0, len);
@@ -119,3 +121,5 @@ RPC_STATUS WINAPI I_RpcGetBufferMarshall(PRPC_MESSAGE RpcMsg)
memset(RpcMsg->Buffer, 0xcd, RpcMsg->BufferLength);
return 0;
}
+
+#endif /* _WIN32_WINNT < 0x600 */