Robert Shearman : rpcrt4: Skip over the right-hand-side data for the protocol floor so

Alexandre Julliard julliard at wine.codeweavers.com
Sat Jun 3 05:24:32 CDT 2006


Module: wine
Branch: refs/heads/master
Commit: 6a11aba526cd2e5cc87a0ca81b214772cdff5c61
URL:    http://source.winehq.org/git/?p=wine.git;a=commit;h=6a11aba526cd2e5cc87a0ca81b214772cdff5c61

Author: Robert Shearman <rob at codeweavers.com>
Date:   Fri Jun  2 20:45:09 2006 +0100

rpcrt4: Skip over the right-hand-side data for the protocol floor so
that we can parse the towers received from native rpcrt4.

---

 dlls/rpcrt4/rpc_transport.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/dlls/rpcrt4/rpc_transport.c b/dlls/rpcrt4/rpc_transport.c
index 34634b5..1a574d2 100644
--- a/dlls/rpcrt4/rpc_transport.c
+++ b/dlls/rpcrt4/rpc_transport.c
@@ -864,10 +864,12 @@ RPC_STATUS RpcTransport_ParseTopOfTower(
     if ((protocol_floor->count_lhs != sizeof(protocol_floor->protid)) ||
         (protocol_floor->count_rhs > tower_size))
         return EPT_S_NOT_REGISTERED;
+    tower_data += protocol_floor->count_rhs;
+    tower_size -= protocol_floor->count_rhs;
 
     floor4 = (twr_empty_floor_t *)tower_data;
     if ((tower_size < sizeof(*floor4)) ||
-        (floor4->count_lhs != sizeof(protocol_floor->protid)))
+        (floor4->count_lhs != sizeof(floor4->protid)))
         return EPT_S_NOT_REGISTERED;
 
     for(i = 0; i < MAX_PROTSEQ; i++)




More information about the wine-cvs mailing list