stefan pushed a commit to branch elementary-1.7.

commit 4bce980afffd7f274c7ce5551fa547a2ed57587e
Author: Stefan Schmidt <[email protected]>
Date:   Thu Dec 13 14:17:29 2012 +0000

    elm/naviframe: Fix potential deref of freed memory.
    
    We should not free it and then access the same data again on line below.
    
    SVN revision: 80862
---
 ChangeLog               | 4 ++++
 NEWS                    | 7 +++++++
 src/lib/elc_naviframe.c | 2 +-
 3 files changed, 12 insertions(+), 1 deletion(-)

diff --git a/ChangeLog b/ChangeLog
index 8f7856f..af3ddec 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -817,3 +817,7 @@
 2013-04-09  WooHyun Jung
 
         * When ctxpopup includes elm_list, elm_list should get focus when 
ctxpopup is shown.
+
+2013-06-10  Stefan Schmidt
+
+        * Fix potential free'ed memory dereference in naviframe
diff --git a/NEWS b/NEWS
index 582ab36..09f656a 100644
--- a/NEWS
+++ b/NEWS
@@ -1,3 +1,10 @@
+Changes since Elementary 1.7.7:
+-------------------------
+
+Fixes:
+
+   * Fix potential free'ed memory dereference in naviframe.
+
 Elementary 1.7.7
 
 Changes since Elementary 1.7.6:
diff --git a/src/lib/elc_naviframe.c b/src/lib/elc_naviframe.c
index 5e035b8..db73a33 100644
--- a/src/lib/elc_naviframe.c
+++ b/src/lib/elc_naviframe.c
@@ -600,10 +600,10 @@ _title_content_set(Elm_Naviframe_Item *it,
                   eina_stringshare_del(pair->part);
                   it->content_list = eina_inlist_remove(it->content_list,
                                                         EINA_INLIST_GET(pair));
-                  free(pair);
                   evas_object_event_callback_del(pair->content,
                                                  EVAS_CALLBACK_DEL,
                                                  _title_content_del);
+                  free(pair);
                   break;
                }
           }

-- 

------------------------------------------------------------------------------
How ServiceNow helps IT people transform IT departments:
1. A cloud service to automate IT design, transition and operations
2. Dashboards that offer high-level views of enterprise services
3. A single system of record for all IT processes
http://p.sf.net/sfu/servicenow-d2d-j

Reply via email to