From e30c547b63c07f6387eec9d164af6ac19743c0ed Mon Sep 17 00:00:00 2001 From: Seunghun Lee Date: Sat, 22 Aug 2020 03:29:13 +0900 Subject: [PATCH] e_comp_wl: remove a frame resource from cached frame list. this fixes a crash caused by trying to an invalid frame resource which is destroyed, but dangling from cached frame list. Change-Id: I3cf097c4b493fec3090a06dfa7f766b934ac2873 --- src/bin/e_comp_wl.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/bin/e_comp_wl.c b/src/bin/e_comp_wl.c index d65180c518..fe3352937f 100644 --- a/src/bin/e_comp_wl.c +++ b/src/bin/e_comp_wl.c @@ -2843,6 +2843,7 @@ static void _e_comp_wl_frame_cb_destroy(struct wl_resource *resource) { E_Client *ec; + E_Comp_Wl_Subsurf_Data *sdata; if (!(ec = wl_resource_get_user_data(resource))) return; if (e_object_is_del(E_OBJECT(ec))) @@ -2863,6 +2864,13 @@ _e_comp_wl_frame_cb_destroy(struct wl_resource *resource) ec->comp_data->pending.frames = eina_list_remove(ec->comp_data->pending.frames, resource); } + + sdata = ec->comp_data->sub.data; + if ((sdata) && (sdata->cached.frames)) + { + sdata->cached.frames = + eina_list_remove(sdata->cached.frames, resource); + } } static void -- 2.34.1