Skip to content

Commit

Permalink
Fix handshake for arti-client
Browse files Browse the repository at this point in the history
As requirement for `arti-client`, added a flush method call in the `HandshakeMachine` writing round.
  • Loading branch information
yukibtc committed Jun 20, 2024
1 parent bef231d commit 2ceb32f
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/handshake/machine.rs
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ impl<Stream: Read + Write> HandshakeMachine<Stream> {
HandshakeState::Writing(mut buf) => {
assert!(buf.has_remaining());
if let Some(size) = self.stream.write(Buf::chunk(&buf)).no_block()? {
self.stream.flush()?;
assert!(size > 0);
buf.advance(size);
Ok(if buf.has_remaining() {
Expand Down

0 comments on commit 2ceb32f

Please sign in to comment.