summaryrefslogtreecommitdiff
path: root/src/Handover.zig
diff options
context:
space:
mode:
Diffstat (limited to 'src/Handover.zig')
-rw-r--r--src/Handover.zig4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/Handover.zig b/src/Handover.zig
index 549e4d58..d245a6af 100644
--- a/src/Handover.zig
+++ b/src/Handover.zig
@@ -385,8 +385,6 @@ fn carry(io: std.Io, job: *Job) void {
job.post(job.post_ctx, job.seq, false, "the new window did not come up in 15 s");
}
-extern "c" fn readdir(dir: *libc.DIR) ?*libc.dirent;
-
/// The registry entry of the window the pointer was let go over, asked of
/// every window by its `status` (`pointer in`): Wayland tells no client
/// where any window is, only whether the pointer is over its own, and the
@@ -404,7 +402,7 @@ fn windowUnderPointer(io: std.Io, job: *Job, out: *[512]u8) std.Io.Cancelable!?[
const dir = libc.opendir(reg) orelse return null;
defer _ = libc.closedir(dir);
var windows: usize = 0;
- while (readdir(dir)) |ent| {
+ while (libc.readdir(dir)) |ent| {
const name = std.mem.sliceTo(&ent.name, 0);
if (name.len == 0 or name[0] == '.') continue;
const entry = std.fmt.bufPrintSentinel(out, "{s}/{s}", .{ reg, name }, 0) catch continue;