e_comp_wl_data: add exceptional return for x clients 25/123025/1
authorJuyeon Lee <juyeonne.lee@samsung.com>
Tue, 4 Apr 2017 07:43:44 +0000 (16:43 +0900)
committerJuyeon Lee <juyeonne.lee@samsung.com>
Tue, 4 Apr 2017 07:43:51 +0000 (16:43 +0900)
e_comp_wl_data_device_send_enter support server side dnd
btw, it is not considering x clients, so added exception
not to pass uninitialized variable 'data_device_res' as wl_data_device parameter

Change-Id: I4ab8b0702272b2874c45caaa0fa421c9aee5111f

src/bin/e_comp_wl_data.c

index f73923623448e42c0b2c28c15516a92925659398..2dbbc5c1be033f6df1bcdd796be1768cad681886 100644 (file)
@@ -735,11 +735,14 @@ e_comp_wl_data_device_send_enter(E_Client *ec)
    if (!e_client_has_xwindow(ec))
      {
         data_device_res =
-              e_comp_wl_data_find_for_client(wl_resource_get_client(ec->comp_data->surface));
+           e_comp_wl_data_find_for_client(wl_resource_get_client(ec->comp_data->surface));
         if (!data_device_res) return;
         offer_res = e_comp_wl_data_device_send_offer(ec);
         if (e_comp_wl->drag_source && (!offer_res)) return;
      }
+   else
+     return;
+
    e_comp_wl->selection.target = ec;
    evas_object_event_callback_add(ec->frame, EVAS_CALLBACK_DEL, _e_comp_wl_data_device_target_del, ec);