Skip to content

Commit 41a74f0

Browse files
valpackett0xpr03
authored andcommitted
kqueue: fix build on FreeBSD
The kqueue crate supports platform-specific events, so the build was failing on FreeBSD with: error[E0004]: non-exhaustive patterns: `Open`, `CloseWrite` and `Close` not covered
1 parent baafb16 commit 41a74f0

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/kqueue.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -263,6 +263,10 @@ impl EventLoop {
263263
remove_watches.push(path.clone());
264264
Ok(Event::new(EventKind::Remove(RemoveKind::Any)).add_path(path))
265265
}
266+
267+
// On different BSD variants, different extra events may be present
268+
#[allow(unreachable_patterns)]
269+
_ => Ok(Event::new(EventKind::Other)),
266270
};
267271
self.event_handler.handle_event(event);
268272
}

0 commit comments

Comments
 (0)