jypark pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=d0d9747853899fba27787c07d9e63530ab9542f2

commit d0d9747853899fba27787c07d9e63530ab9542f2
Author: Ji-Youn Park <jy0703.p...@samsung.com>
Date:   Thu Dec 24 13:11:45 2015 +0830

       ecore_x: fix memory leak
    
       fix memory leak in xcb event handler.
       @fix
---
 src/lib/ecore_x/xcb/ecore_xcb_e.c      | 2 ++
 src/lib/ecore_x/xcb/ecore_xcb_events.c | 1 +
 2 files changed, 3 insertions(+)

diff --git a/src/lib/ecore_x/xcb/ecore_xcb_e.c 
b/src/lib/ecore_x/xcb/ecore_xcb_e.c
index 313954b..fae51b5 100644
--- a/src/lib/ecore_x/xcb/ecore_xcb_e.c
+++ b/src/lib/ecore_x/xcb/ecore_xcb_e.c
@@ -259,6 +259,8 @@ ecore_x_e_window_profile_get(Ecore_X_Window win)
    if (atom)
      profile = ecore_x_atom_name_get(atom[0]);
 
+   if (data) free(data);
+
    return profile;
 }
 
diff --git a/src/lib/ecore_x/xcb/ecore_xcb_events.c 
b/src/lib/ecore_x/xcb/ecore_xcb_events.c
index 9f1e2fc..3d4a495 100644
--- a/src/lib/ecore_x/xcb/ecore_xcb_events.c
+++ b/src/lib/ecore_x/xcb/ecore_xcb_events.c
@@ -1491,6 +1491,7 @@ 
_ecore_xcb_event_handle_client_message(xcb_generic_event_t *event)
                     e->types[i] = ecore_x_atom_name_get(types[i]);
                }
              e->num_types = num_ret;
+             if (data) free(data);
           }
         else
           {

-- 


Reply via email to