raster pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=c5a5302e069ad1e624319ca17c17ecfb8634c9c6
commit c5a5302e069ad1e624319ca17c17ecfb8634c9c6 Author: Carsten Haitzler (Rasterman) <[email protected]> Date: Mon Jul 31 15:07:28 2017 +0900 evas - handle devices that on deletion delete other devices on shutdown this fixes a whole bunch of warnings that just recently turned up... --- src/lib/evas/canvas/evas_device.c | 12 +++++++++++- src/lib/evas/include/evas_private.h | 1 + 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/src/lib/evas/canvas/evas_device.c b/src/lib/evas/canvas/evas_device.c index d352b3c69f..7f93b77801 100644 --- a/src/lib/evas/canvas/evas_device.c +++ b/src/lib/evas/canvas/evas_device.c @@ -78,6 +78,7 @@ _del_cb(void *data, const Efl_Event *ev) { Evas_Public_Data *e = data; + e->devices_modified = EINA_TRUE; // can not be done in std destructor e->devices = eina_list_remove(e->devices, ev->object); @@ -473,9 +474,18 @@ _evas_device_cleanup(Evas *eo_e) /* If the device is deleted, _del_cb will remove the device from the devices list. */ +again: + e->devices_modified = EINA_FALSE; cpy = eina_list_clone(e->devices); EINA_LIST_FREE(cpy, dev) - evas_device_del(dev); + { + evas_device_del(dev); + if (e->devices_modified) + { + eina_list_free(cpy); + goto again; + } + } /* Not all devices were deleted. The user probably will unref them later. Since Evas will be deleted, remove the del callback from them and diff --git a/src/lib/evas/include/evas_private.h b/src/lib/evas/include/evas_private.h index f055bc09c6..3124f83c5c 100644 --- a/src/lib/evas/include/evas_private.h +++ b/src/lib/evas/include/evas_private.h @@ -977,6 +977,7 @@ struct _Evas_Public_Data Eina_Bool render2 : 1; Eina_Bool common_init : 1; Eina_Bool inside_post_render : 1; + Eina_Bool devices_modified : 1; }; struct _Evas_Layer --
