Skip to content

Commit

Permalink
Merge pull request #1 from simonschoening/feature/rmdir
Browse files Browse the repository at this point in the history
✨ Add support to rmdir operation
  • Loading branch information
simonschoening authored Jun 21, 2023
2 parents 905f182 + 6f2dfde commit 6f42e18
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions library/std/src/sys/hermit/fs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -531,8 +531,8 @@ pub fn set_perm(_p: &Path, perm: FilePermissions) -> io::Result<()> {
match perm.0 {}
}

pub fn rmdir(_p: &Path) -> io::Result<()> {
unsupported()
pub fn rmdir(path: &Path) -> io::Result<()> {
run_path_with_cstr(path, |path| cvt(unsafe { abi::rmdir(path.as_ptr()) }).map(|_| ()))
}

pub fn remove_dir_all(_path: &Path) -> io::Result<()> {
Expand Down

0 comments on commit 6f42e18

Please sign in to comment.