commit 4ea7470417b7b0c1069a0bc67d93511d3c06a2bf (tree)
parent a84402d7963c08f72e571da7fd0bea2b57aca411
Author: Ryan Liptak <squeek502@hotmail.com>
Date: Wed, 14 Jul 2021 18:06:53 -0700
Add inotify_rm_watch definition to c/linux.zig
Also make inotify_add_watch's pathname marked as nul-terminated
Diffstat:
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/lib/std/c/linux.zig b/lib/std/c/linux.zig
@@ -94,7 +94,8 @@ pub extern "c" fn epoll_pwait(
sigmask: *const sigset_t,
) c_int;
pub extern "c" fn inotify_init1(flags: c_uint) c_int;
-pub extern "c" fn inotify_add_watch(fd: fd_t, pathname: [*]const u8, mask: u32) c_int;
+pub extern "c" fn inotify_add_watch(fd: fd_t, pathname: [*:0]const u8, mask: u32) c_int;
+pub extern "c" fn inotify_rm_watch(fd: fd_t, wd: c_int) c_int;
/// See std.elf for constants for this
pub extern "c" fn getauxval(__type: c_ulong) c_ulong;