In fact the node should never be NULL or something is really going wrong.

SVN revision: 35732
This commit is contained in:
Cedric BAIL 2008-08-29 13:50:25 +00:00
parent c0e5707e30
commit 1b9d254f52
2 changed files with 5 additions and 5 deletions

View File

@ -281,8 +281,8 @@ struct _Eina_Rbtree_Int
static Eina_Rbtree_Direction
eina_rbtree_int_cmp(const Eina_Rbtree_Int *left, const Eina_Rbtree_Int *right)
{
if (!left) return EINA_RBTREE_RIGHT;
if (!right) return EINA_RBTREE_LEFT;
fail_if(!left);
fail_if(!right);
if (left->value < right->value) return EINA_RBTREE_LEFT;
return EINA_RBTREE_RIGHT;

View File

@ -85,8 +85,8 @@ struct _Eina_Rbtree_Int
static Eina_Rbtree_Direction
eina_rbtree_int_cmp(const Eina_Rbtree_Int *left, const Eina_Rbtree_Int *right, __UNUSED__ void *data)
{
if (!left) return EINA_RBTREE_RIGHT;
if (!right) return EINA_RBTREE_LEFT;
fail_if(!left);
fail_if(!right);
if (left->value < right->value) return EINA_RBTREE_LEFT;
return EINA_RBTREE_RIGHT;
@ -95,7 +95,7 @@ eina_rbtree_int_cmp(const Eina_Rbtree_Int *left, const Eina_Rbtree_Int *right, _
static int
eina_rbtree_int_key(const Eina_Rbtree_Int *node, const int *key, __UNUSED__ int length, __UNUSED__ void *data)
{
if (!node) return 1;
fail_if(!node);
return node->value - *key;
}