stefan pushed a commit to branch master.

http://git.enlightenment.org/core/elementary.git/commit/?id=9b5cd12e689523f60d175dea7e3c6ad3880ca535

commit 9b5cd12e689523f60d175dea7e3c6ad3880ca535
Author: Stefan Schmidt <s.schm...@samsung.com>
Date:   Fri Jan 23 12:43:49 2015 +0100

    elm_image: Fix memory leak in GETDAT macro.
    
    Free data2 on error path.
    
    CID: 1265609, 1265610, 1265611, 1265612
---
 src/lib/elm_image.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/src/lib/elm_image.c b/src/lib/elm_image.c
index 4ca45fa..75881e4 100644
--- a/src/lib/elm_image.c
+++ b/src/lib/elm_image.c
@@ -1131,7 +1131,10 @@ _elm_image_smart_rotate_180(Elm_Image_Data *sd)
    w = neww; h = newh; \
    evas_object_image_size_set(sd->img, w, h); \
    data = evas_object_image_data_get(sd->img, EINA_TRUE); \
-   if (!data) return
+   if (!data) { \
+      free(data2); \
+      return; \
+   } \
 
 #define PUTDAT \
    evas_object_image_data_set(sd->img, data); \

-- 


Reply via email to