Skip to content

Commit 04553a0

Browse files
committed
vfs file: drop -> close file
1 parent 809c3a5 commit 04553a0

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/vfs/file.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,12 @@ impl File {
2020
}
2121
}
2222

23+
fn drop(&self) {
24+
vfs_request(&self.path, VfsAction::CloseFile)
25+
.send()
26+
.unwrap();
27+
}
28+
2329
/// Reads the entire file, from start position.
2430
/// Returns a vector of bytes.
2531
pub fn read(&self) -> Result<Vec<u8>, VfsError> {

0 commit comments

Comments
 (0)