Fixed NULL pointer dereferences 42/88742/2 accepted/tizen/common/20160920.131935 accepted/tizen/ivi/20160920.231744 accepted/tizen/mobile/20160920.231636 accepted/tizen/tv/20160920.231655 accepted/tizen/wearable/20160920.231718 submit/tizen/20160920.023021
authorMinJeong Kim <minjjj.kim@samsung.com>
Tue, 20 Sep 2016 11:07:41 +0000 (20:07 +0900)
committerMinJeong Kim <minjjj.kim@samsung.com>
Tue, 20 Sep 2016 12:39:32 +0000 (21:39 +0900)
Change-Id: I616b62ab828604a902b7845e5d77966998c4d84f

src/bin/e_comp_wl_input.c
src/bin/e_pixmap.c

index f54c329..0b982fd 100644 (file)
@@ -236,7 +236,8 @@ _e_comp_wl_input_cb_keyboard_get(struct wl_client *client, struct wl_resource *r
 
    /* if the client owns the focused surface, we need to send an enter */
    focused = e_client_focused_get();
-   if (!focused) return;
+   if ((!focused) || (e_object_is_del(E_OBJECT(focused))) ||
+       (!focused->comp_data) || (!focused->comp_data->surface)) return;
 
    if (client != wl_resource_get_client(focused->comp_data->surface)) return;
    e_comp_wl->kbd.focused = eina_list_append(e_comp_wl->kbd.focused, res);
index 2bfe489..1d74176 100644 (file)
@@ -1061,7 +1061,8 @@ e_pixmap_buffer_clear(E_Pixmap *cp)
      }
 
    /* release the helded buffer by e_client */
-   e_comp_wl_buffer_reference(&cp->client->comp_data->buffer_ref, NULL);
+   if (cp->client->comp_data)
+     e_comp_wl_buffer_reference(&cp->client->comp_data->buffer_ref, NULL);
 
    /* composite object clear */
    e_comp_object_clear(cp->client->frame);