Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: Cleanups for write_appdata_frames #1440

Merged
merged 13 commits into from
Apr 16, 2024
10 changes: 6 additions & 4 deletions neqo-transport/src/connection/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1911,10 +1911,6 @@ impl Connection {
}
}

// Check if there is a Datagram to be written
self.quic_datagrams
.write_frames(builder, tokens, &mut self.stats.borrow_mut());

let stats = &mut self.stats.borrow_mut().frame_tx;

self.streams
Expand Down Expand Up @@ -1945,6 +1941,12 @@ impl Connection {
return Ok(());
}

// Check if there is a Datagram to be written
// Currently we're giving them priority over user streams; they could be moved
// to after them (after Normal)
self.quic_datagrams
.write_frames(builder, tokens, &mut self.stats.borrow_mut());

self.streams
.write_frames(TransmissionPriority::Normal, builder, tokens, stats);
if builder.is_full() {
Expand Down