forked from enlightenment/efl
and when deleting a hash item - if hash data != NULL delete EXACTLY that
entry (if there are duplicates... this will avoid removing the wrong one) SVN revision: 36092
This commit is contained in:
parent
c4624ffa93
commit
bcabb2be60
|
@ -248,6 +248,8 @@ evas_hash_del(Evas_Hash *hash, const char *key, const void *data)
|
|||
{
|
||||
el = (Evas_Hash_El *)l;
|
||||
if (!strcmp(el->key, key))
|
||||
{
|
||||
if ((!data) || (el->data == data))
|
||||
{
|
||||
hash->buckets[hash_num] = evas_object_list_remove(hash->buckets[hash_num], el);
|
||||
free(el);
|
||||
|
@ -261,6 +263,7 @@ evas_hash_del(Evas_Hash *hash, const char *key, const void *data)
|
|||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return hash;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue