From 13b09ae9ef4a15e6c7a967971cc0f50eec1d6f82 Mon Sep 17 00:00:00 2001 From: irving ou Date: Thu, 25 Jan 2024 12:26:43 -0500 Subject: [PATCH] ci, poll --- src/poll.rs | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/poll.rs b/src/poll.rs index 2e34d76..ff49961 100644 --- a/src/poll.rs +++ b/src/poll.rs @@ -426,6 +426,13 @@ impl EventExtra { pub fn is_pri(&self) -> bool { self.flags.contains(PollFlags::PRI) } + + #[inline] + pub fn is_connect_failed(&self) -> bool { + // need reviewer's special attention, as I do not have access to a system that supports this + // this is a guess based on the documentation of `poll()` + self.flags.contains(PollFlags::ERR) + } } fn cvt_mode_as_remove(mode: PollMode) -> io::Result {