diff options
author | Mikail Bagishov <bagishov.mikail@yandex.ru> | 2020-05-21 20:42:28 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-05-21 19:42:28 +0200 |
commit | 1e54a35325fa371d61c428ead5879a6bb1b0ddf6 (patch) | |
tree | 447d100ec00371b09f3aa3da99f00e6a0d0fecb8 /tokio/src/fs | |
parent | 4f4f4807c3fe21cbfde82d894f044636b52cb04b (diff) |
io: remove zeroing for AsyncRead implementors (#2525)
Diffstat (limited to 'tokio/src/fs')
-rw-r--r-- | tokio/src/fs/file.rs | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/tokio/src/fs/file.rs b/tokio/src/fs/file.rs index cc4a187d..f3bc9854 100644 --- a/tokio/src/fs/file.rs +++ b/tokio/src/fs/file.rs @@ -537,6 +537,11 @@ impl File { } impl AsyncRead for File { + unsafe fn prepare_uninitialized_buffer(&self, _buf: &mut [std::mem::MaybeUninit<u8>]) -> bool { + // https://github.com/rust-lang/rust/blob/09c817eeb29e764cfc12d0a8d94841e3ffe34023/src/libstd/fs.rs#L668 + false + } + fn poll_read( mut self: Pin<&mut Self>, cx: &mut Context<'_>, |