rpcrt4: Fix the sending of >5800 byte messages by only adding offset
to the buffer after the first batch of data has been written to the pipe.
This commit is contained in:
parent
b4fe7ea7c6
commit
a4000349f8
|
@ -261,8 +261,6 @@ RPC_STATUS RPCRT4_Send(RpcConnection *Connection, RpcPktHdr *Header,
|
|||
Header->common.frag_len = BufferLength + hdr_size;
|
||||
} else {
|
||||
Header->common.frag_len = Connection->MaxTransmissionSize;
|
||||
buffer_pos += Header->common.frag_len - hdr_size;
|
||||
BufferLength -= Header->common.frag_len - hdr_size;
|
||||
}
|
||||
|
||||
/* transmit packet header */
|
||||
|
@ -283,6 +281,8 @@ RPC_STATUS RPCRT4_Send(RpcConnection *Connection, RpcPktHdr *Header,
|
|||
return GetLastError();
|
||||
}
|
||||
|
||||
buffer_pos += Header->common.frag_len - hdr_size;
|
||||
BufferLength -= Header->common.frag_len - hdr_size;
|
||||
Header->common.flags &= ~RPC_FLG_FIRST;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue