From: duna.oh Date: Fri, 28 Jun 2024 01:48:14 +0000 (+0900) Subject: Revert "e_devicemgr: Do not send device_remove event if no object found by id in... X-Git-Tag: accepted/tizen/8.0/unified/20240705.163555~6 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F72%2F313572%2F1;p=platform%2Fupstream%2Fenlightenment.git Revert "e_devicemgr: Do not send device_remove event if no object found by id in client's map" It is better not to use wl_client_get_object() APIs for thread safety. This reverts commit d2df60e1e8d4dd4aee54dc40754f01b318a1a69f. Change-Id: I05c7e40e43a90b6977ae57a71400c31b66434b0c --- diff --git a/src/bin/e_devicemgr_wl.c b/src/bin/e_devicemgr_wl.c index 429d5764e0..440a460e11 100644 --- a/src/bin/e_devicemgr_wl.c +++ b/src/bin/e_devicemgr_wl.c @@ -193,8 +193,7 @@ void e_devicemgr_wl_device_del(E_Devicemgr_Input_Device *dev) { struct wl_resource *res; - struct wl_client *wc; - uint32_t serial, res_id; + uint32_t serial; E_Devicemgr_Input_Device_User_Data *device_user_data; serial = wl_display_next_serial(e_comp_wl->wl.disp); @@ -202,24 +201,11 @@ e_devicemgr_wl_device_del(E_Devicemgr_Input_Device *dev) EINA_LIST_FREE(dev->resources, res) { device_user_data = wl_resource_get_user_data(res); - if (!device_user_data) continue; if (!device_user_data->dev_mgr_res || !device_user_data->seat_res || !device_user_data->dev_res) continue; - res_id = wl_resource_get_id(res); - wc = wl_resource_get_client(res); - if (wl_client_get_object(wc, res_id) != res) - { - pid_t pid; - wl_client_get_credentials(wc, &pid, NULL, NULL); - - DMERR("No device_remove sent: PID@%d id@%u path:%s", - pid, res_id, dev->identifier); - continue; - } - device_user_data->dev = NULL; tizen_input_device_manager_send_device_remove( device_user_data->dev_mgr_res,