From 863e66b003717f3085e1b16d3b13e674353be772 Mon Sep 17 00:00:00 2001 From: Emil Velikov Date: Tue, 4 Apr 2017 18:07:34 +0100 Subject: [PATCH] compositor-drm: correctly set the version of the drmEventContext We implement v2 so use that instead of the DRM_EVENT_CONTEXT_VERSION macro. The latter defines the version of the drmEventContext struct declared in the header [used in the current build] and can be 2, 3 or even 1000. Signed-off-by: Emil Velikov Reviewed-by: Daniel Stone --- libweston/compositor-drm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libweston/compositor-drm.c b/libweston/compositor-drm.c index e27bc1d4..095f427c 100644 --- a/libweston/compositor-drm.c +++ b/libweston/compositor-drm.c @@ -1623,7 +1623,7 @@ on_drm_input(int fd, uint32_t mask, void *data) drmEventContext evctx; memset(&evctx, 0, sizeof evctx); - evctx.version = DRM_EVENT_CONTEXT_VERSION; + evctx.version = 2; evctx.page_flip_handler = page_flip_handler; evctx.vblank_handler = vblank_handler; drmHandleEvent(fd, &evctx);