diff options
| author | Tomasz Miąsko <tomasz.miasko@gmail.com> | 2020-07-06 00:00:00 +0000 |
|---|---|---|
| committer | Tomasz Miąsko <tomasz.miasko@gmail.com> | 2020-07-26 12:25:02 +0200 |
| commit | 7a5d3abfb1aa3a38e0b3b3508c760fc8e712226c (patch) | |
| tree | d3ecc55568eb086edafea073317a190475cdb310 /src/libstd/sys/windows/stack_overflow.rs | |
| parent | 461707c5a119cc33c5d7df585ddb6cbec4a081bf (diff) | |
| download | rust-7a5d3abfb1aa3a38e0b3b3508c760fc8e712226c.tar.gz rust-7a5d3abfb1aa3a38e0b3b3508c760fc8e712226c.zip | |
Avoid writes without any data in `Write::write_all_vectored`
Previously, when non-empty sequence of empty IoSlices have been provided to `Write::write_all_vectored`, the buffers would be written as is with `Write::write_vectored` and subsequently the return value `Ok(0)` would be misinterpreted as an error. Avoid writes without any data by advancing the buffers first. This matches the documented behaviour of `Write::write_all_vectored` and is analogous to what happens in `Write::write_all`.
Diffstat (limited to 'src/libstd/sys/windows/stack_overflow.rs')
0 files changed, 0 insertions, 0 deletions
