Commit Graph

835 Commits

Author SHA1 Message Date
Andrew Talbot
3c14ae6699 rpcrt4: Remove unneeded casts. 2008-01-17 13:42:14 +01:00
Rob Shearman
68c8e5fe41 rpcrt4: Add tests for RPC_FC_P_DEREF|RPC_FC_P_ONSTACK pointers. 2008-01-16 15:34:26 +01:00
Francois Gouget
f6fab295f3 Fix spelling error in the generated conformance test files. 2008-01-16 12:46:18 +01:00
Rob Shearman
ffffcfa239 rpcrt4: Move the setting of retval_ptr outside of any particular stub phase in stub_do_args and stub_do_old_args.
After the change in order of phases it was no longer being set in the 
last phase and so caused all stubless functions to appear to have no 
return value.
2008-01-16 12:15:51 +01:00
Rob Shearman
1a3d7c77a5 rpcrt4: Allow NULL networkaddr and endpoint in rpcrt4_np_get_top_of_tower.
Add tests for this.
2008-01-15 14:35:35 +01:00
Rob Shearman
ed5b296289 rpcrt4: The initialisation of [out] variables in the stubless code must be after the unmarshaling of [in] and [in, out] variables has been completed.
This is because the size of an [out] variable could depend on a
conformance value stored in an unmarshalled [in] or [in,out] variable.
2008-01-14 15:31:37 +01:00
Rob Shearman
4f6142b8d9 rpcrt4: Handle complex arrays in calc_arg_size. 2008-01-14 15:31:37 +01:00
Rob Shearman
aabfc52573 rpcrt4: Fix the calculation of element sizes for complex arrays by using a new function ComplexStructSize that doesn't touch the buffer to calculate the size.
Otherwise, this would fail on arrays with a conformance or variance of zero.
2008-01-14 15:31:37 +01:00
Rob Shearman
516008ff5f rpcrt4: Add traces to the start of TowerConstruct and TowerExplode. 2008-01-14 13:39:08 +01:00
Rob Shearman
4402daa00b rpcrt4: Don't print fixmes for NDR types without a freeing function.
Not all types have a freeing function.
2008-01-14 13:39:03 +01:00
Rob Shearman
97b842c817 rpcrt4: Add support for calculating the memory size of complex types with embedded non-conformant strings. 2008-01-14 13:38:58 +01:00
Rob Shearman
576c9dc6fa rpcrt4: Allocate a context handle if a NULL GUID is being unmarshalled. 2008-01-14 13:38:53 +01:00
Rob Shearman
a04641c15b rpcrt4: Split RPCRT4_process_packet out into separate functions. 2008-01-11 12:25:59 +01:00
Rob Shearman
492947aa02 rpcrt4: Fix a memory leak in the cstub tests. 2008-01-09 13:38:02 +01:00
Rob Shearman
24ba6a5cc6 rpcrt4: Fix memory leaks in the ndr_marshall tests. 2008-01-09 13:38:02 +01:00
Rob Shearman
52f08dd510 rpcrt4: Fix memory leak in NdrFullPointerXlatFree.
First of all, the code was freeing the wrong pointer (i.e. the pointer
supplied by the caller of one of the NdrFullPointer* functions, not the
PFULL_PTR_TO_REFID_ELEMENT. Second, the code wasn't following the Next
link to the next entry in the list.
2008-01-09 13:38:02 +01:00
Rob Shearman
5be085dec5 rpcrt4: Fix a leak of msg in RPCRT4_io_thread on the error paths. 2008-01-09 12:25:56 +01:00
Rob Shearman
e0c67a189b rpcrt4: Implement NdrMapCommAndFaultStatus.
Add tests for this function.
2008-01-09 12:25:50 +01:00
Rob Shearman
c370980dfa rpcrt4: Use send on a socket instead of write as it's more portable. 2008-01-09 12:25:46 +01:00
Rob Shearman
af4639f74a rpcrt4: Improve error handling in RPCRT4_io_thread and remove commented-out code. 2008-01-08 14:02:56 +01:00
Rob Shearman
d0f914befc rpcrt4: Bind to the server interface in I_RpcGetBuffer, not I_RpcSendReceive.
The actual sending of the request is still done in I_RpcSendReceive though.

Disallow the server from calling I_RpcSend and I_RpcReceive to allow 
simplification of the code. The releasing of the connection is now done 
in I_RpcFreeBuffer.

Implement I_RpcNegotiateTransferSyntax.
2008-01-08 14:00:50 +01:00
Rob Shearman
bb78c3f86d rpcrt4: Remove some unused includes. 2008-01-08 14:00:46 +01:00
Rob Shearman
9ff15252d0 rpcrt4: Set the fBufferValid flag in NdrProxyGetBuffer.
Only call IRpcChannelBuffer_FreeBuffer in NdrProxyFreeBuffer if 
fBufferValid is set.
2008-01-08 14:00:44 +01:00
Rob Shearman
e2e7916739 rpcrt4: Set ReservedForRuntime to NULL in NdrClientInitializeNew. 2008-01-07 22:55:48 +01:00
Rob Shearman
ea44471088 rpcrt4: Implement RpcAsyncInitializeHandle. 2008-01-07 22:55:46 +01:00
Rob Shearman
1da9d47f1b rpcrt4: Add tests for some async RPC functions. 2008-01-07 22:55:44 +01:00
Rob Shearman
fef28ec6cb rpcrt4: Add stubs for asynchronous functions. 2008-01-07 22:55:41 +01:00
Rob Shearman
b0cbf664f6 rpcrt4: Add stubs for I_RpcAsyncSetHandle and I_RpcAsyncAbortCall. 2008-01-07 22:55:39 +01:00
Rob Shearman
807a203f77 rpcrt4: Call NdrCorrelationInitialize and NdrCorrelationFree from NdrClientCall2 if new correlation descriptors have been specified. 2008-01-07 22:55:37 +01:00
Rob Shearman
23c9b6c161 rpcrt4: Add stubs for NdrCorrelationInitialize, NdrCorrelationPass and NdrCorrelationFree. 2008-01-07 22:55:34 +01:00
Rob Shearman
f9a54a58d5 rpcrt4: ndr_stubless.h should include ndrtypes.h as it depends on types it defines. 2008-01-07 22:55:32 +01:00
Rob Shearman
31676530c2 rpcrt4: Set the ProcNum of RPC_MESSAGE in NdrClientInitializeNew to include RPC_VALID_FLAGS_BIT.
Mask out RPC_VALID_FLAGS_BIT from ProcNum when it is used to build a 
packet to send to the server.
2008-01-07 22:55:28 +01:00
Rob Shearman
4d6aa7ca95 rpcrt4: Add tests for the RPC_MESSAGE members set by NdrClientInitializeNew. 2008-01-07 22:55:22 +01:00
Rob Shearman
f296a8ca6c rpcrt4: Implement I_RpcMapWin32Status.
Add a test for this function.
2008-01-07 12:41:17 +01:00
Rob Shearman
a0410bef34 rpcrt4: Print fixme's if the serialize or no-serialize flags are set on a context handle being marshalled or unmarshalled. 2008-01-07 12:32:31 +01:00
Rob Shearman
f9fc52f602 rpcrt4: Pass the interface identifier to the lower-level context handle routines for context handles with the strict flag set. 2008-01-07 12:32:07 +01:00
Rob Shearman
0e6d5202c8 rpcrt4: Don't set Buffer to NULL in I_RpcFreeBuffer. 2008-01-07 12:04:31 +01:00
Rob Shearman
1bb6c1b4d1 rpcrt4: Add some tests for NdrGetBuffer and NdrFreeBuffer. 2008-01-07 12:04:28 +01:00
Rob Shearman
c8b3dc40a4 rpcrt4: Update todos. 2008-01-07 12:02:52 +01:00
Rob Shearman
56da854c21 rpcrt4: Fix NdrGetBuffer to set the correct fields in the MIDL_STUB_MESSAGE structure.
Fix NdrFreeBuffer to use the fBufferValid flag to determine whether or 
not I_RpcFreeBuffer needs to be called.
2007-12-31 17:14:34 +01:00
Rob Shearman
4aff0cdac4 rpcrt4: Make some variables in the tests static. 2007-12-31 17:14:29 +01:00
Rob Shearman
07622b0f05 rpcrt4: Add tests for NdrServerInitializeNew. 2007-12-31 17:14:22 +01:00
Rob Shearman
e745f93c79 rpcrt4: Fix the MIDL_STUB_MESSAGE fields set by NdrServerInitializeNew. 2007-12-31 17:14:16 +01:00
Rob Shearman
f6a29a1e73 rpcrt4: Fix a case of destroying a context handle without first releasing the lock.
Reverse the order of the release statements in NDRSContextMarshall2 for 
the case where the context handle doesn't have valid data so that the 
release that releases the lock comes first and then the optional second 
release doesn't need to release the lock.
2007-12-31 17:14:04 +01:00
Rob Shearman
51c051c0c4 rpcrt4: Keep a track of server context handles allocated during processing of a request.
Release them after processing of a request has finished to avoid a slow 
memory leak if the association isn't released for ages.
2007-12-31 17:13:55 +01:00
Rob Shearman
86a0b1d24e rpcrt4: Implement NdrConformantStringMemorySize. 2007-12-31 16:47:55 +01:00
Rob Shearman
274dc73ba1 rpcrt4: Add some tests for non-conformant strings. 2007-12-31 16:46:16 +01:00
Rob Shearman
eeeed91d92 rpcrt4: Implement non-conformant string functions. 2007-12-31 16:46:10 +01:00
Rob Shearman
3e8a032e8b rpcrt4: Re-use existing memory for embedded pointers in NdrVaryingArrayUnmarshall. 2007-12-26 14:02:58 +01:00
Rob Shearman
273766ee6f rpcrt4: Re-use existing memory for embedded pointers in NdrConformantVaryingArrayUnmarshall. 2007-12-26 14:02:55 +01:00