Remove useless calls to ResetEvent.

svn path=/trunk/; revision=13860
This commit is contained in:
Eric Kohl 2005-03-06 21:01:04 +00:00
parent d0c2c28b81
commit d95010663e

View file

@ -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();