aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Ser <contact@emersion.fr>2021-07-19 14:49:52 +0200
committerSimon Zeni <simon@bl4ckb0ne.ca>2021-07-19 09:01:21 -0400
commitf94eb174c793c09adad8fbadb3333b22f28ee743 (patch)
treea4a4ca3395e9f5dff59418c148f25f40d2e141ae
parenta93b18dbd5a43735709c59590fa0bff427dd888d (diff)
backend/drm: fix NULL data in handle_drm_event
wl_event_loop_add_fd was called with a NULL data argument, but the function expects the data argument to be set to the wlr_drm_backend. Fixes: 053ebe7c278b ("backend/drm: terminate display on drmHandleEvent failure")
-rw-r--r--backend/drm/backend.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/backend/drm/backend.c b/backend/drm/backend.c
index a1c7ce9c..eb22d1a3 100644
--- a/backend/drm/backend.c
+++ b/backend/drm/backend.c
@@ -215,7 +215,7 @@ struct wlr_backend *wlr_drm_backend_create(struct wl_display *display,
struct wl_event_loop *event_loop = wl_display_get_event_loop(display);
drm->drm_event = wl_event_loop_add_fd(event_loop, drm->fd,
- WL_EVENT_READABLE, handle_drm_event, NULL);
+ WL_EVENT_READABLE, handle_drm_event, drm);
if (!drm->drm_event) {
wlr_log(WLR_ERROR, "Failed to create DRM event source");
goto error_fd;