X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/a12698abb72c090dba6907506781ae979b0ef606..fdbd931b8e3a85c62dfd75d4fce8df10442c3be3:/src/unix/epolldispatcher.cpp diff --git a/src/unix/epolldispatcher.cpp b/src/unix/epolldispatcher.cpp index b5b7a8cce6..d42c4fea3b 100644 --- a/src/unix/epolldispatcher.cpp +++ b/src/unix/epolldispatcher.cpp @@ -194,7 +194,11 @@ wxEpollDispatcher::DoPoll(epoll_event *events, int numEvents, int timeout) const bool wxEpollDispatcher::HasPending() const { epoll_event event; - return DoPoll(&event, 1, 0) == 1; + + // NB: it's not really clear if epoll_wait() can return a number greater + // than the number of events passed to it but just in case it can, use + // >= instead of == here, see #10397 + return DoPoll(&event, 1, 0) >= 1; } int wxEpollDispatcher::Dispatch(int timeout)