From b57b184b45ed9a9f00e1025a3e6e625c786c4125 Mon Sep 17 00:00:00 2001 From: glima Date: Fri, 6 Aug 2010 21:21:16 +0000 Subject: [PATCH] Bad free() at state_copy(). MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit By Fidêncio. git-svn-id: svn+ssh://svn.enlightenment.org/var/svn/e/trunk/edje@50874 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33 --- src/lib/edje_edit.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/lib/edje_edit.c b/src/lib/edje_edit.c index 64d643d..bfc7172 100644 --- a/src/lib/edje_edit.c +++ b/src/lib/edje_edit.c @@ -2945,7 +2945,8 @@ edje_edit_state_copy(Evas_Object *obj, const char *part, const char *from, doubl /* Update pointers. */ for (i = 0; i < img_to->image.tweens_count; ++i) free(img_to->image.tweens[i]); - free(img_to->image.tweens); + if (img_to->image.tweens_count > 0) + free(img_to->image.tweens); img_to->image.tweens_count = img_from->image.tweens_count; img_to->image.tweens = calloc(img_to->image.tweens_count, -- 2.7.4