quinn-rs / quinn

Async-friendly QUIC implementation in Rust
Apache License 2.0
3.76k stars 380 forks source link

`quinn::Connection` wakers should be cleaned up more aggressively #1459

Closed Ralith closed 1 year ago

Ralith commented 1 year ago

quinn::Connection stores a variety of wakers, particularly for dispatching stream events. In some cases (e.g. #1458) these might not get disposed of on all paths, especially if futures are canceled by dropping. We should ensure that all futures which manually register wakers (or equivalent) clean them up n Drop. Futures built on tokio::sync::Notify broadcasts don't have this issue as Notified takes care of itself.