diff --git a/src/lib.rs b/src/lib.rs index 52450e13f3..e77c095aea 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -321,6 +321,10 @@ pub fn with_redoxfs(disk: D, password_opt: Option<&[u8]>, callback: F) join_handle.join().unwrap(); + if cfg!(not(target_os = "redox")) { + fs::remove_dir_all(&mount_path)?; + } + res }