Harden stream queues and hostile network tests
ci / test (push) Has been cancelled
ci / fuzz-smoke (push) Has been cancelled
ci / windows-client (push) Has been cancelled
ci / package-release (linux-x86_64, ubuntu-latest) (push) Has been cancelled
ci / package-release (macos-aarch64, macos-14) (push) Has been cancelled
ci / package-release (macos-x86_64, macos-13) (push) Has been cancelled
ci / package-release (windows-x86_64, windows-latest) (push) Has been cancelled
ci / remote-bench (push) Has been cancelled

This commit is contained in:
DuProcess
2026-07-11 17:33:49 -04:00
parent 99e318ca6b
commit bae0d0ed56
6 changed files with 33 additions and 12 deletions
+3 -1
View File
@@ -6253,7 +6253,9 @@ async fn flush_stream_pending_data(
if credit < bytes.len() {
break;
}
let bytes = pending.pop_front().expect("pending front exists");
let Some(bytes) = pending.pop_front() else {
break;
};
*stream_send_credit.entry(stream_id).or_default() -= bytes.len();
let offset = *stream_next_send_offset.entry(stream_id).or_default();
stream_next_send_offset.insert(stream_id, offset.saturating_add(bytes.len() as u64));