forked from enlightenment/efl
eina_rbtree: avoid defererencing null pointer
Summary: Pointer 'it->stack' is dereferenced at `_eina_rbtree_iterator_free`. Reviewers: Hermet, zmike Reviewed By: Hermet Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D11346
This commit is contained in:
parent
9768a5ad98
commit
fff6ce7f2e
|
@ -231,7 +231,11 @@ _eina_rbtree_iterator_build(const Eina_Rbtree *root, unsigned char mask)
|
|||
eina_trash_init(&it->trash);
|
||||
|
||||
it->stack = eina_array_new(8);
|
||||
if (!it->stack) goto on_error;
|
||||
if (!it->stack)
|
||||
{
|
||||
free(it);
|
||||
return NULL;
|
||||
}
|
||||
}
|
||||
|
||||
first = _eina_rbtree_iterator_list_new(it, root);
|
||||
|
|
Loading…
Reference in New Issue