ecore: Fix _ecore_animator_shutdown (double free)
authorJean-Philippe Andre <jp.andre@samsung.com>
Tue, 21 Jun 2016 01:14:13 +0000 (10:14 +0900)
committerJean-Philippe Andre <jp.andre@samsung.com>
Tue, 21 Jun 2016 01:14:13 +0000 (10:14 +0900)
evas 3d examples would always exit on a double free, since
EINA_INLIST_FREE was misused. Not surprising considering
it's different from EINA_LIST_FREE but has a similar name.

src/lib/ecore/ecore_anim.c

index 707916c..4bf148d 100644 (file)
@@ -750,6 +750,8 @@ _ecore_animator_shutdown(void)
         if (animator->suspended) animators_suspended--;
         if (animator->delete_me) animators_delete_me--;
 
+        animators = (Ecore_Animator *) eina_inlist_remove
+              (EINA_INLIST_GET(animators), EINA_INLIST_GET(animator));
         free(animator);
      }
 }