From 3f4db8f58db4775619a9ae241ab93e4395c76b2d Mon Sep 17 00:00:00 2001 From: Nikolay Kim Date: Sun, 12 May 2024 19:29:21 +0500 Subject: [PATCH] fix test --- CHANGES.md | 4 +++- src/io.rs | 1 - src/v3/dispatcher.rs | 5 ++--- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/CHANGES.md b/CHANGES.md index 8a3fef9..4f27dbb 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -8,7 +8,9 @@ * Remove protocol variant services -* Disable keep-alive timer is not configured +* Disable keep-alive timer if not configured + +* Add write back-pressure to io dispatcher ## [1.1.0] - 2024-03-07 diff --git a/src/io.rs b/src/io.rs index edd2917..79ec567 100644 --- a/src/io.rs +++ b/src/io.rs @@ -1051,7 +1051,6 @@ mod tests { /// Do not use keep-alive timer if not configured #[ntex::test] async fn test_no_keepalive_err_after_frame_timeout() { - env_logger::init(); let (client, server) = Io::create(); client.remote_buffer_cap(1024); diff --git a/src/v3/dispatcher.rs b/src/v3/dispatcher.rs index 43c257f..3a655e0 100644 --- a/src/v3/dispatcher.rs +++ b/src/v3/dispatcher.rs @@ -411,12 +411,11 @@ where inner.inflight.borrow_mut().remove(&res.packet_id); Some(codec::Packet::UnsubscribeAck { packet_id: res.packet_id }) } - ControlAckKind::Disconnect - | ControlAckKind::Closed - | ControlAckKind::Nothing => { + ControlAckKind::Disconnect => { inner.sink.close(); None } + ControlAckKind::Closed | ControlAckKind::Nothing => None, ControlAckKind::PublishAck(_) => unreachable!(), }; return Ok(packet);