We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 913678e commit e62b4dfCopy full SHA for e62b4df
src/lib.rs
@@ -1577,12 +1577,12 @@ impl<'conn> Statement<'conn> {
1577
1578
let mut buf = vec![];
1579
loop {
1580
- match std::io::copy(&mut r.take(16 * 1024), &mut buf) {
+ match r.take(16 * 1024).read_to_end(&mut buf) {
1581
Ok(0) => break,
1582
- Ok(len) => {
+ Ok(_) => {
1583
try_desync!(conn, conn.stream.write_message(
1584
&CopyData {
1585
- data: &buf[..len as usize],
+ data: &buf,
1586
}));
1587
buf.clear();
1588
}
0 commit comments