3 ms·
Linking to discussions from pre-1.0 does not help your assertion. std::fs::File's impl of std::io::Read: https://github.com/rust-lang/rust/blob/7fc048f0712ba5
by Arnavion 6y ago
Linking to discussions from pre-1.0 does not help your assertion.
std::fs::File's impl of std::io::Read:
https://github.com/rust-lang/rust/blob/7fc048f0712ba515ca11fac204921b9ad8a0c5a3/library/std/src/fs.rs#L610-L612 https://github.com/rust-lang/rust/blob/7fc048f0712ba515ca11f...
-> https://github.com/rust-lang/rust/blob/7fc048f0712ba515ca11fac204921b9ad8a0c5a3/library/std/src/sys/unix/fs.rs#L778-L780 https://github.com/rust-lang/rust/blob/7fc048f0712ba515ca11f...
-> https://github.com/rust-lang/rust/blob/7fc048f0712ba515ca11fac204921b9ad8a0c5a3/library/std/src/sys/unix/fd.rs#L68-L73 https://github.com/rust-lang/rust/blob/7fc048f0712ba515ca11f...
Again, as I said, it corresponds one-to-one with a call to the underlying read API. The retries for ErrorKind::Interrupted are done by higher abstractions like std::io::Read::read_exact, and they explicitly document that they do this.
https://github.com/rust-lang/rust/blob/7fc048f0712ba515ca11fac204921b9ad8a0c5a3/library/std/src/io/mod.rs#L775 https://github.com/rust-lang/rust/blob/7fc048f0712ba515ca11f...
- networkimprov 6y agoApologies if I got this wrong, but you've linked read(), and I'm referring to mkdir() et al. Have they taken out the EINTR retries which were added for the issue I linked?
- Arnavion 6y agostd::fs::create_dir: https://github.com/rust-lang/rust/blob/7fc048f0712ba515ca11fac204921b9ad8a0c5a3/library/std/src/fs.rs#L1876-L1878 https://github.com/rust-lang/rust/blob/7fc048f0712ba515ca11f... -> https://github.com/rust-lang/rust/blob/7fc048f0712ba515ca11fac204921b9ad8a0c5a3/library/std/src/fs.rs#L2158-L2161 https://github.com/rust-lang/rust/blob/7fc048f0712ba515ca11f... -> https://github.com/rust-lang/rust/blob/7fc048f0712ba515ca11fac204921b9ad8a0c5a3/library/std/src/fs.rs#L2163-L2165 https://github.com/rust-lang/rust/blob/7fc048f0712ba515ca11f... -> https://github.com/rust-lang/rust/blob/7fc048f0712ba515ca11fac204921b9ad8a0c5a3/library/std/src/sys/unix/fs.rs#L851-L855 https://github.com/rust-lang/rust/blob/7fc048f0712ba515ca11f...