From 9f4703c1044da3967d2c4e0bd1cb0eb4422e5438 Mon Sep 17 00:00:00 2001 From: Drew DeVault Date: Wed, 30 Nov 2022 13:25:20 +0100 Subject: [PATCH] filemod: add EPOLLONESHOT We might not always want this; in the future we might want to disable this by default for things like accept(2), or let the user disable it to reuse buffers and auto-queue new reads. --- ev/+linux/file.ha | 2 +- diff --git a/ev/+linux/file.ha b/ev/+linux/file.ha index 01db94908217af2725d8921b9c1b1a6362015d86..161bd71e43c77adb93fe16562394dc45ae6f00fa 100644 --- a/ev/+linux/file.ha +++ b/ev/+linux/file.ha @@ -62,7 +62,7 @@ // Modifies the epoll events for a given file. For internal use. fn filemod(file: *file, events: u32) void = { let ev = rt::epoll_event { - events = events, + events = events | rt::EPOLLONESHOT, ... }; ev.data.ptr = file; -- 2.48.1