We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent cd03960 commit 0e201e8Copy full SHA for 0e201e8
src/common/buf.rs
@@ -75,7 +75,7 @@ impl<T: Buf> Buf for BufList<T> {
75
// Our inner buffer may have an optimized version of copy_to_bytes, and if the whole
76
// request can be fulfilled by the front buffer, we can take advantage.
77
match self.bufs.front_mut() {
78
- Some(front) if front.remaining() == len => self.bytes.pop_front().unwrap(),
+ Some(front) if front.remaining() == len => self.bufs.pop_front().unwrap(),
79
Some(front) if front.remaining() > len => front.copy_to_bytes(len),
80
_ => {
81
assert!(len <= self.remaining(), "`len` greater than remaining");
0 commit comments