From: Gwanglim Lee Date: Thu, 14 May 2015 05:06:20 +0000 (+0900) Subject: add null check to prevent segmentation fault when releasing input panel surface X-Git-Tag: accepted/tizen/common/20150518.072009~2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=23fd5aff4e260607e1702e92f7dc7f9dbdbe3d42;p=platform%2Fcore%2Fuifw%2Fe-mod-tizen-wl-textinput.git add null check to prevent segmentation fault when releasing input panel surface Change-Id: I0c58168672fa0018c41c27d1faf163ef37d2d9f2 --- diff --git a/src/e_mod_input_panel.c b/src/e_mod_input_panel.c index 920b816..61cbc6f 100644 --- a/src/e_mod_input_panel.c +++ b/src/e_mod_input_panel.c @@ -223,6 +223,14 @@ _e_input_panel_surface_unmap(struct wl_resource *resource) return; } + if (!ec->comp_data) + { + wl_resource_post_error(resource, + WL_DISPLAY_ERROR_INVALID_OBJECT, + "No Client For Input Panel Surface"); + return; + } + if (ec->comp_data->mapped) { ec->visible = EINA_FALSE;