added _remove_all

This commit is contained in:
jasonkercher
2022-03-07 17:16:03 -05:00
parent 658a605c75
commit 1f19610fd6
3 changed files with 126 additions and 27 deletions
+8
View File
@@ -1537,6 +1537,10 @@ sys_open :: proc(path: cstring, flags: int, mode: int = 0o000) -> int {
}
}
sys_openat :: proc(dfd: int, path: cstring, flags: int, mode: int = 0o000) -> int {
return int(intrinsics.syscall(SYS_openat, uintptr(dfd), uintptr(rawptr(path)), uintptr(flags), uintptr(mode)))
}
sys_close :: proc(fd: int) -> int {
return int(intrinsics.syscall(SYS_close, uintptr(fd)))
}
@@ -1701,6 +1705,10 @@ sys_unlink :: proc(path: cstring) -> int {
}
}
sys_unlinkat :: proc(dfd: int, path: cstring, flag: int = 0) -> int {
return int(intrinsics.syscall(SYS_unlinkat, uintptr(dfd), uintptr(rawptr(path)), flag))
}
sys_rmdir :: proc(path: cstring) -> int {
when ODIN_ARCH != .arm64 {
return int(intrinsics.syscall(SYS_rmdir, uintptr(rawptr(path))))