diff --git a/reactos/lib/rpcrt4/rpc_message.c b/reactos/lib/rpcrt4/rpc_message.c index d10e56c9ab4..0e48cb631ff 100644 --- a/reactos/lib/rpcrt4/rpc_message.c +++ b/reactos/lib/rpcrt4/rpc_message.c @@ -265,7 +265,6 @@ RPC_STATUS RPCRT4_Send(RpcConnection *Connection, RpcPktHdr *Header, } /* transmit packet header */ - ResetEvent(Connection->ovl.hEvent); if (!WriteFile(Connection->conn, Header, hdr_size, &count, &Connection->ovl)) { WARN("WriteFile failed with error %ld\n", GetLastError()); return GetLastError(); @@ -282,7 +281,6 @@ RPC_STATUS RPCRT4_Send(RpcConnection *Connection, RpcPktHdr *Header, } /* send the fragment data */ - ResetEvent(Connection->ovl.hEvent); if (!WriteFile(Connection->conn, buffer_pos, Header->common.frag_len - hdr_size, &count, &Connection->ovl)) { WARN("WriteFile failed with error %ld\n", GetLastError()); return GetLastError(); @@ -319,7 +317,6 @@ RPC_STATUS RPCRT4_Receive(RpcConnection *Connection, RpcPktHdr **Header, TRACE("(%p, %p, %p)\n", Connection, Header, pMsg); /* read packet common header */ - ResetEvent(Connection->ovl.hEvent); if (!ReadFile(Connection->conn, &common_hdr, sizeof(common_hdr), &dwRead, &Connection->ovl)) { WARN("ReadFile failed with error %ld\n", GetLastError()); status = RPC_S_PROTOCOL_ERROR; @@ -355,7 +352,6 @@ RPC_STATUS RPCRT4_Receive(RpcConnection *Connection, RpcPktHdr **Header, memcpy(*Header, &common_hdr, sizeof(common_hdr)); /* read the rest of packet header */ - ResetEvent(Connection->ovl.hEvent); if (!ReadFile(Connection->conn, &(*Header)->common + 1, hdr_length - sizeof(common_hdr), &dwRead, &Connection->ovl)) { WARN("ReadFile failed with error %ld\n", GetLastError()); @@ -403,7 +399,6 @@ RPC_STATUS RPCRT4_Receive(RpcConnection *Connection, RpcPktHdr **Header, } if (data_length == 0) dwRead = 0; else { - ResetEvent(Connection->ovl.hEvent); if (!ReadFile(Connection->conn, buffer_ptr, data_length, &dwRead, &Connection->ovl)) { WARN("ReadFile failed with error %ld\n", GetLastError()); status = RPC_S_PROTOCOL_ERROR; @@ -433,7 +428,6 @@ RPC_STATUS RPCRT4_Receive(RpcConnection *Connection, RpcPktHdr **Header, TRACE("next header\n"); /* read the header of next packet */ - ResetEvent(Connection->ovl.hEvent); if (!ReadFile(Connection->conn, *Header, hdr_length, &dwRead, &Connection->ovl)) { WARN("ReadFile failed with error %ld\n", GetLastError()); status = GetLastError();