Hello all,

In elm_index.c, _item_del_pre_hook calls _item_free, where it->letter
is not set to NULL after eina_stringshare_del.
This will cause invalid access later on.  The attached patch fixes the
problem, which is reproducible in my code before the fix.
Please check if this makes sense.

I am sorry that I was unable come up with a simple test app to
demonstrate the problem.

Thanks in advance.


Brian

-- 
brian
------------------

Cool-Karaoke - The smallest recording studio, in your palm, open-sourced
http://cool-idea.com.tw/

iMaGiNaTiOn iS mOrE iMpOrTaNt tHaN kNoWlEdGe
Index: src/lib/elm_index.c
===================================================================
--- src/lib/elm_index.c (revision 75713)
+++ src/lib/elm_index.c (working copy)
@@ -29,7 +29,10 @@
    ELM_INDEX_DATA_GET(WIDGET(it), sd);
 
    sd->items = eina_list_remove(sd->items, it);
-   if (it->letter) eina_stringshare_del(it->letter);
+   if (it->letter) {
+          eina_stringshare_del(it->letter);
+          it->letter = NULL;
+   }
 }
 
 static void
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel

Reply via email to