diff options
author | Boram Park <boram1288.park@samsung.com> | 2015-12-03 08:36:13 +0900 |
---|---|---|
committer | Inki Dae <inki.dae@samsung.com> | 2015-12-02 18:32:33 -0800 |
commit | b8b52e15688b0e080d4b459f1701c29819d41728 (patch) | |
tree | 998b3376920f464a1dcd5f26b6baf70a7f642721 | |
parent | 7ff94383aa546fc188e846e5f6a64e42afbbaee7 (diff) | |
download | libdrm-b8b52e15688b0e080d4b459f1701c29819d41728.tar.gz libdrm-b8b52e15688b0e080d4b459f1701c29819d41728.tar.bz2 libdrm-b8b52e15688b0e080d4b459f1701c29819d41728.zip |
check if user_handler_list inited
Change-Id: I95abd7e8cc8d0485a7cc06dca54bfa46775eb8aa
-rw-r--r-- | xf86drmMode.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/xf86drmMode.c b/xf86drmMode.c index b8381159..24c8851e 100644 --- a/xf86drmMode.c +++ b/xf86drmMode.c @@ -962,8 +962,10 @@ int drmHandleEvent(int fd, drmEventContextPtr evctx) { struct drm_user_handler_data *data; int ret = -1; + if (!user_handler_list_init) + break; DRMLISTFOREACHENTRY(data, &user_handler_list, link) { - if (data->fd == fd && data->handler) + if (data->handler) { ret = data->handler(e); if (ret == 0) |