From 37aa8399dec5c47ddd0667ee2d596a40f3770f0e Mon Sep 17 00:00:00 2001 From: InHong Han Date: Mon, 9 Mar 2020 10:58:41 +0900 Subject: [PATCH] Reduce the wait time for key processing to prevent deadlock Change-Id: I0767287e996b870e4ec70cc25f9250907f584186 --- ism/extras/wayland_immodule/wayland_imcontext.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/ism/extras/wayland_immodule/wayland_imcontext.c b/ism/extras/wayland_immodule/wayland_imcontext.c index 1a99d92..3b0c85a 100644 --- a/ism/extras/wayland_immodule/wayland_imcontext.c +++ b/ism/extras/wayland_immodule/wayland_imcontext.c @@ -55,7 +55,7 @@ #define IME_DEVICE_NAME "ime" #define HIDE_TIMER_INTERVAL 0.05 -#define WAIT_FOR_FILTER_DONE_SECOND 2 +#define WAIT_FOR_FILTER_DONE_SECOND 1.3 #define MOD_SHIFT_MASK 0x01 #define MOD_CAPS_MASK 0x02 @@ -3394,6 +3394,11 @@ wayland_im_context_filter_event(Ecore_IMF_Context *ctx, break; } + if (ecore_time_get() - start_time > WAIT_FOR_FILTER_DONE_SECOND) { + LOGE("Key processing result not received"); + ret = EINA_FALSE; + } + if (imcontext->last_key_event_filter.serial < serial) { LOGW("Timeout occured"); ret = EINA_TRUE; -- 2.7.4