discomfitor pushed a commit to branch master.

commit 1b8c6fc89af60b4f13c5748478e4c71f261bc295
Author: Mike Blumenkrantz <[email protected]>
Date:   Mon May 20 10:25:49 2013 +0100

    fix possible memleak when creating new app menu entries
    
    klocwork issue
---
 src/bin/e_int_menus.c | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/src/bin/e_int_menus.c b/src/bin/e_int_menus.c
index 0d916ca..6a3badd 100644
--- a/src/bin/e_int_menus.c
+++ b/src/bin/e_int_menus.c
@@ -723,7 +723,13 @@ _e_int_menus_app_config_append(Efreet_Desktop *desktop)
    EINA_LIST_FOREACH_SAFE(e_config->menu_applications, l, l_next, ma)
      {
         if ((!strcmp(ma->orig_path, cma->orig_path)) && (ma->load_time == 
cma->load_time))
-          return ma->exec_valid;
+          {
+             eina_stringshare_del(cma->orig_path);
+             eina_stringshare_del(cma->try_exec);
+             eina_stringshare_del(cma->exec);
+             free(cma);
+             return ma->exec_valid;
+          }
 
         if ((!strcmp(ma->orig_path, cma->orig_path)) && (ma->load_time != 
cma->load_time))
           {

-- 

------------------------------------------------------------------------------
AlienVault Unified Security Management (USM) platform delivers complete
security visibility with the essential security capabilities. Easily and
efficiently configure, manage, and operate all of your security controls
from a single console and one unified framework. Download a free trial.
http://p.sf.net/sfu/alienvault_d2d

Reply via email to