From: Shinwoo Kim Date: Tue, 9 Feb 2021 07:23:19 +0000 (+0900) Subject: ecore_wl2_subsurface: remove double free X-Git-Tag: accepted/tizen/unified/20210215.131008^0 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F66%2F253366%2F2;p=platform%2Fupstream%2Fefl.git ecore_wl2_subsurface: remove double free User could use ecore_wl2_subsurface API as below. if (!ecore_wl2_subsurface_video_surface_prepare) ecore_wl2_subsurface_del; If video_surface_prepare frees subsurface when it gets a failure, then del also tries to free the subsurface again. (double free) It does not make sense to release subsurface in video_surface_prepare. So this patch is removing the line to free subsurface. *tizen_fix Change-Id: I5da0c10f59ebae5d7b4406f8ad93dacb082bb285 --- diff --git a/src/lib/ecore_wl2/ecore_wl2_subsurf.c b/src/lib/ecore_wl2/ecore_wl2_subsurf.c index a4d0162..4df56a3 100644 --- a/src/lib/ecore_wl2/ecore_wl2_subsurf.c +++ b/src/lib/ecore_wl2/ecore_wl2_subsurf.c @@ -285,7 +285,7 @@ create_buf_err: subsurface->wl.tbm_surface = NULL; client_init_err: - _ecore_wl2_subsurf_free(subsurface); + subsurface->video = EINA_FALSE; return EINA_FALSE; }