From 9be90a5c5a2f282be9b27f4de44607994a98f228 Mon Sep 17 00:00:00 2001 From: tiago Date: Tue, 3 Aug 2010 14:27:47 +0000 Subject: [PATCH] Call only once the eina_list_last(_edje_file_cache) git-svn-id: svn+ssh://svn.enlightenment.org/var/svn/e/trunk/edje@50768 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33 --- src/lib/edje_cache.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/lib/edje_cache.c b/src/lib/edje_cache.c index 36b0310..c57b487 100644 --- a/src/lib/edje_cache.c +++ b/src/lib/edje_cache.c @@ -455,10 +455,12 @@ _edje_cache_file_clean(void) count = eina_list_count(_edje_file_cache); while ((_edje_file_cache) && (count > _edje_file_cache_size)) { + Eina_List *last; Edje_File *edf; - edf = eina_list_data_get(eina_list_last(_edje_file_cache)); - _edje_file_cache = eina_list_remove_list(_edje_file_cache, eina_list_last(_edje_file_cache)); + last = eina_list_last(_edje_file_cache); + edf = eina_list_data_get(last); + _edje_file_cache = eina_list_remove_list(_edje_file_cache, last); _edje_file_free(edf); count = eina_list_count(_edje_file_cache); } -- 2.7.4