From e7cda051435c924df01e318e0225e86062c48de4 Mon Sep 17 00:00:00 2001 From: Joonbum Ko Date: Fri, 30 Nov 2018 17:47:27 +0900 Subject: [PATCH] tpl_wayland_egl_thread: Changed the result of handle_events() to assert checking. - If tdm_source is destroyed when the result of tdm_client_handle_events() is not TDM_ERROR_NONE, tdm releated functions can not be recovered. - Unless error is unexpected, tdm_client_handle_events() should always return ERROR_NONE, otherwise it should be checked with assert to make debugging easier for unknown ERROR. Change-Id: I6681fc396772e7e4d692145cc702257b42a57fde Signed-off-by: Joonbum Ko --- src/tpl_wayland_egl_thread.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/src/tpl_wayland_egl_thread.c b/src/tpl_wayland_egl_thread.c index dbdf3b6..6cdbbd2 100644 --- a/src/tpl_wayland_egl_thread.c +++ b/src/tpl_wayland_egl_thread.c @@ -368,11 +368,7 @@ _twe_thread_tdm_source_dispatch(GSource *source, GSourceFunc cb, gpointer data) if (cond & G_IO_IN) { tdm_err = tdm_client_handle_events(tdm_source->tdm_client); - if (tdm_err != TDM_ERROR_NONE) { - TPL_ERR("TDM_ERROR:%d tdm_client:%p\n", - tdm_err, tdm_source->tdm_client); - return G_SOURCE_REMOVE; - } + TPL_ASSERT(tdm_err == TDM_ERROR_NONE); } return G_SOURCE_CONTINUE; -- 2.7.4