fix memory corruption at free time.
That list pointer could be corrupted because inside of the enventor_item_del(), the list head pointer could be modified.
This commit is contained in:
parent
9504c8a634
commit
c6cff4bef8
|
@ -94,8 +94,12 @@ static void
|
||||||
_enventor_sub_items_free(Enventor_Object_Data *pd)
|
_enventor_sub_items_free(Enventor_Object_Data *pd)
|
||||||
{
|
{
|
||||||
Enventor_Item *it;
|
Enventor_Item *it;
|
||||||
EINA_LIST_FREE(pd->sub_its, it)
|
|
||||||
enventor_item_del(it);
|
while(pd->sub_its)
|
||||||
|
{
|
||||||
|
it = eina_list_data_get(pd->sub_its);
|
||||||
|
enventor_item_del(it);
|
||||||
|
}
|
||||||
pd->sub_its = NULL;
|
pd->sub_its = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue