summaryrefslogtreecommitdiff
path: root/src/wlstate.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/wlstate.cc')
-rw-r--r--src/wlstate.cc5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/wlstate.cc b/src/wlstate.cc
index 5233868..940a011 100644
--- a/src/wlstate.cc
+++ b/src/wlstate.cc
@@ -114,7 +114,10 @@ void wayc_wlstate_update(struct wlstate_s* state) {
i32 rc = poll(&pfd, 1, 0);
if (rc == -1) wayc_panic("Failed to poll Wayland eventfd");
- if (!(pfd.revents & POLLIN)) return;
+ if (!(pfd.revents & POLLIN)) {
+ wl_display_dispatch_pending(state->display);
+ return;
+ }
rc = wl_display_dispatch(state->display);
if (rc == -1) wayc_panic("Failed to dispatch Wayland events");