diff options
author | Canop <cano.petrole@gmail.com> | 2020-01-19 13:26:30 +0100 |
---|---|---|
committer | Canop <cano.petrole@gmail.com> | 2020-01-19 13:26:30 +0100 |
commit | 80a936cd2930b024b8510ba00a6a492bdf7bdd5b (patch) | |
tree | defcc1ae523a6d710a0f0a1afa1cd3ed1331add6 /src/file_sizes/file_sizes_default.rs | |
parent | 437fb4f70548fff2aa39ede101518e88355da4ca (diff) |
fix windows compilation
Diffstat (limited to 'src/file_sizes/file_sizes_default.rs')
-rw-r--r-- | src/file_sizes/file_sizes_default.rs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/file_sizes/file_sizes_default.rs b/src/file_sizes/file_sizes_default.rs index 97091d8..ed5832d 100644 --- a/src/file_sizes/file_sizes_default.rs +++ b/src/file_sizes/file_sizes_default.rs @@ -11,6 +11,7 @@ use { thread, time::Duration, }, + super::FileSize, }; // Note that this version doesn't try to compute the real size taken @@ -75,6 +76,6 @@ pub fn compute_dir_size(path: &Path, tl: &TaskLifetime) -> Option<u64> { pub fn compute_file_size(path: &Path) -> FileSize { match fs::metadata(path) { Ok(m) => FileSize::new(m.len(), false), - Err(_) => 0, + Err(_) => FileSize::new(0, false), } } |