diff options
| author | Matthias Krüger <matthias.krueger@famsik.de> | 2022-10-01 16:45:04 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-10-01 16:45:04 +0200 |
| commit | 21fc2185325fcf6f1a002e4c0c015fecff2ac888 (patch) | |
| tree | 5f8406b67ad4a16fe0efc6fb209c84bf9cc54679 /library/std/src/sys/unix/stack_overflow.rs | |
| parent | 744e397d8855f7da87d70aa8d0bd9e0f5f0b51a1 (diff) | |
| parent | c66860ab3ed7861458fca2fba4a7e5f512571537 (diff) | |
| download | rust-21fc2185325fcf6f1a002e4c0c015fecff2ac888.tar.gz rust-21fc2185325fcf6f1a002e4c0c015fecff2ac888.zip | |
Rollup merge of #101675 - beetrees:set-times-no-panic, r=joshtriplett
Improve `File::set_times` error handling
Makes `File::set_times` return an error if the `SystemTime` cannot fit into the required type instead of panicking in `FileTimes::set_{accessed,modified}`. Also makes `File::set_times` return an error on Windows if either of the passed times are `0xFFFF_FFFF_FFFF_FFFF`, as [the documentation for `SetFileTime`](https://docs.microsoft.com/en-us/windows/win32/api/fileapi/nf-fileapi-setfiletime) states that this will prevent operations on the file handle from updating the corresponding file time instead of setting the corresponding file time to that value.
Tracking issue: #98245
Diffstat (limited to 'library/std/src/sys/unix/stack_overflow.rs')
0 files changed, 0 insertions, 0 deletions
