Skip to content

Commit

Permalink
Fix TCP, WS, QUIC leaking connection ids in reject()
Browse files Browse the repository at this point in the history
  • Loading branch information
dmitry-markin committed Aug 7, 2024
1 parent 3b664f7 commit 4632f26
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 3 deletions.
1 change: 0 additions & 1 deletion src/transport/quic/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -285,7 +285,6 @@ impl Transport for QuicTransport {
}

fn reject(&mut self, connection_id: ConnectionId) -> crate::Result<()> {
self.canceled.insert(connection_id);
self.pending_open
.remove(&connection_id)
.map_or(Err(Error::ConnectionDoesntExist(connection_id)), |_| Ok(()))
Expand Down
1 change: 0 additions & 1 deletion src/transport/tcp/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -310,7 +310,6 @@ impl Transport for TcpTransport {
}

fn reject(&mut self, connection_id: ConnectionId) -> crate::Result<()> {
self.canceled.insert(connection_id);
self.pending_open
.remove(&connection_id)
.map_or(Err(Error::ConnectionDoesntExist(connection_id)), |_| Ok(()))
Expand Down
1 change: 0 additions & 1 deletion src/transport/websocket/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -379,7 +379,6 @@ impl Transport for WebSocketTransport {
}

fn reject(&mut self, connection_id: ConnectionId) -> crate::Result<()> {
self.canceled.insert(connection_id);
self.pending_open
.remove(&connection_id)
.map_or(Err(Error::ConnectionDoesntExist(connection_id)), |_| Ok(()))
Expand Down

0 comments on commit 4632f26

Please sign in to comment.