(path: &Path, bytes: &[u8])
| 5016 | } |
| 5017 | |
| 5018 | pub(super) fn write_new_synced(path: &Path, bytes: &[u8]) -> Result<(), RepositoryError> { |
| 5019 | let mut file = OpenOptions::new().write(true).create_new(true).open(path)?; |
| 5020 | file.write_all(bytes)?; |
| 5021 | file.sync_all()?; |
| 5022 | Ok(()) |
| 5023 | } |
| 5024 | |
| 5025 | fn write_atomic_regular(path: &Path, bytes: &[u8], mode: u32) -> Result<(), RepositoryError> { |
| 5026 | let parent = path |
no test coverage detected