forked from enlightenment/efl
parent
874e4df9ee
commit
4210007040
|
@ -356,7 +356,7 @@ void *ecore_hash_get(Ecore_Hash *hash, void *key)
|
||||||
void *data;
|
void *data;
|
||||||
Ecore_Hash_Node *node;
|
Ecore_Hash_Node *node;
|
||||||
|
|
||||||
CHECK_PARAM_POINTER_RETURN("hash", hash, FALSE);
|
CHECK_PARAM_POINTER_RETURN("hash", hash, NULL);
|
||||||
|
|
||||||
node = _ecore_hash_get_node(hash, key);
|
node = _ecore_hash_get_node(hash, key);
|
||||||
if (!node)
|
if (!node)
|
||||||
|
|
|
@ -494,7 +494,7 @@ inline void *ecore_list_remove(Ecore_List * list)
|
||||||
{
|
{
|
||||||
void *ret;
|
void *ret;
|
||||||
|
|
||||||
CHECK_PARAM_POINTER_RETURN("list", list, FALSE);
|
CHECK_PARAM_POINTER_RETURN("list", list, NULL);
|
||||||
|
|
||||||
ret = _ecore_list_remove_0(list);
|
ret = _ecore_list_remove_0(list);
|
||||||
|
|
||||||
|
@ -508,13 +508,13 @@ static void *_ecore_list_remove_0(Ecore_List * list)
|
||||||
Ecore_List_Node *old;
|
Ecore_List_Node *old;
|
||||||
|
|
||||||
if (!list)
|
if (!list)
|
||||||
return FALSE;
|
return NULL;
|
||||||
|
|
||||||
if (ecore_list_is_empty(list))
|
if (ecore_list_is_empty(list))
|
||||||
return FALSE;
|
return NULL;
|
||||||
|
|
||||||
if (!list->current)
|
if (!list->current)
|
||||||
return FALSE;
|
return NULL;
|
||||||
|
|
||||||
if (list->current == list->first)
|
if (list->current == list->first)
|
||||||
return _ecore_list_remove_first(list);
|
return _ecore_list_remove_first(list);
|
||||||
|
@ -569,7 +569,7 @@ inline void *ecore_list_remove_first(Ecore_List * list)
|
||||||
{
|
{
|
||||||
void *ret;
|
void *ret;
|
||||||
|
|
||||||
CHECK_PARAM_POINTER_RETURN("list", list, FALSE);
|
CHECK_PARAM_POINTER_RETURN("list", list, NULL);
|
||||||
|
|
||||||
ret = _ecore_list_remove_first(list);
|
ret = _ecore_list_remove_first(list);
|
||||||
|
|
||||||
|
@ -583,13 +583,13 @@ static void *_ecore_list_remove_first(Ecore_List * list)
|
||||||
Ecore_List_Node *old;
|
Ecore_List_Node *old;
|
||||||
|
|
||||||
if (!list)
|
if (!list)
|
||||||
return FALSE;
|
return NULL;
|
||||||
|
|
||||||
if (ecore_list_is_empty(list))
|
if (ecore_list_is_empty(list))
|
||||||
return FALSE;
|
return NULL;
|
||||||
|
|
||||||
if (!list->first)
|
if (!list->first)
|
||||||
return FALSE;
|
return NULL;
|
||||||
|
|
||||||
old = list->first;
|
old = list->first;
|
||||||
|
|
||||||
|
@ -622,7 +622,7 @@ inline void *ecore_list_remove_last(Ecore_List * list)
|
||||||
{
|
{
|
||||||
void *ret;
|
void *ret;
|
||||||
|
|
||||||
CHECK_PARAM_POINTER_RETURN("list", list, FALSE);
|
CHECK_PARAM_POINTER_RETURN("list", list, NULL);
|
||||||
|
|
||||||
ret = _ecore_list_remove_last(list);
|
ret = _ecore_list_remove_last(list);
|
||||||
|
|
||||||
|
@ -636,13 +636,13 @@ static void *_ecore_list_remove_last(Ecore_List * list)
|
||||||
Ecore_List_Node *old, *prev;
|
Ecore_List_Node *old, *prev;
|
||||||
|
|
||||||
if (!list)
|
if (!list)
|
||||||
return FALSE;
|
return NULL;
|
||||||
|
|
||||||
if (ecore_list_is_empty(list))
|
if (ecore_list_is_empty(list))
|
||||||
return FALSE;
|
return NULL;
|
||||||
|
|
||||||
if (!list->last)
|
if (!list->last)
|
||||||
return FALSE;
|
return NULL;
|
||||||
|
|
||||||
old = list->last;
|
old = list->last;
|
||||||
if (list->current == old)
|
if (list->current == old)
|
||||||
|
@ -689,7 +689,7 @@ inline void *ecore_list_goto_index(Ecore_List * list, int index)
|
||||||
{
|
{
|
||||||
void *ret;
|
void *ret;
|
||||||
|
|
||||||
CHECK_PARAM_POINTER_RETURN("list", list, FALSE);
|
CHECK_PARAM_POINTER_RETURN("list", list, NULL);
|
||||||
|
|
||||||
ret = _ecore_list_goto_index(list, index);
|
ret = _ecore_list_goto_index(list, index);
|
||||||
|
|
||||||
|
@ -703,20 +703,20 @@ static void *_ecore_list_goto_index(Ecore_List *list, int index)
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
if (!list)
|
if (!list)
|
||||||
return FALSE;
|
return NULL;
|
||||||
|
|
||||||
if (ecore_list_is_empty(list))
|
if (ecore_list_is_empty(list))
|
||||||
return FALSE;
|
return NULL;
|
||||||
|
|
||||||
if (index > ecore_list_nodes(list) || index < 0)
|
if (index > ecore_list_nodes(list) || index < 0)
|
||||||
return FALSE;
|
return NULL;
|
||||||
|
|
||||||
_ecore_list_goto_first(list);
|
_ecore_list_goto_first(list);
|
||||||
|
|
||||||
for (i = 0; i < index && _ecore_list_next(list); i++);
|
for (i = 0; i < index && _ecore_list_next(list); i++);
|
||||||
|
|
||||||
if (i >= list->nodes)
|
if (i >= list->nodes)
|
||||||
return FALSE;
|
return NULL;
|
||||||
|
|
||||||
list->index = i;
|
list->index = i;
|
||||||
|
|
||||||
|
@ -734,7 +734,7 @@ inline void *ecore_list_goto(Ecore_List * list, void *data)
|
||||||
{
|
{
|
||||||
void *ret;
|
void *ret;
|
||||||
|
|
||||||
CHECK_PARAM_POINTER_RETURN("list", list, FALSE);
|
CHECK_PARAM_POINTER_RETURN("list", list, NULL);
|
||||||
|
|
||||||
ret = _ecore_list_goto(list, data);
|
ret = _ecore_list_goto(list, data);
|
||||||
|
|
||||||
|
@ -785,7 +785,7 @@ inline void *ecore_list_goto_first(Ecore_List *list)
|
||||||
{
|
{
|
||||||
void *ret;
|
void *ret;
|
||||||
|
|
||||||
CHECK_PARAM_POINTER_RETURN("list", list, FALSE);
|
CHECK_PARAM_POINTER_RETURN("list", list, NULL);
|
||||||
|
|
||||||
ret = _ecore_list_goto_first(list);
|
ret = _ecore_list_goto_first(list);
|
||||||
|
|
||||||
|
@ -814,7 +814,7 @@ inline void *ecore_list_goto_last(Ecore_List * list)
|
||||||
{
|
{
|
||||||
void *ret;
|
void *ret;
|
||||||
|
|
||||||
CHECK_PARAM_POINTER_RETURN("list", list, FALSE);
|
CHECK_PARAM_POINTER_RETURN("list", list, NULL);
|
||||||
|
|
||||||
ret = _ecore_list_goto_last(list);
|
ret = _ecore_list_goto_last(list);
|
||||||
|
|
||||||
|
@ -870,7 +870,7 @@ inline void *ecore_list_next(Ecore_List * list)
|
||||||
{
|
{
|
||||||
void *data;
|
void *data;
|
||||||
|
|
||||||
CHECK_PARAM_POINTER_RETURN("list", list, FALSE);
|
CHECK_PARAM_POINTER_RETURN("list", list, NULL);
|
||||||
|
|
||||||
data = _ecore_list_next(list);
|
data = _ecore_list_next(list);
|
||||||
|
|
||||||
|
@ -1224,7 +1224,7 @@ void *ecore_dlist_remove(Ecore_DList * list)
|
||||||
Ecore_List *l2 = ECORE_LIST(list);
|
Ecore_List *l2 = ECORE_LIST(list);
|
||||||
Ecore_DList_Node *node;
|
Ecore_DList_Node *node;
|
||||||
|
|
||||||
CHECK_PARAM_POINTER_RETURN("list", list, FALSE);
|
CHECK_PARAM_POINTER_RETURN("list", list, NULL);
|
||||||
|
|
||||||
if (l2->current) {
|
if (l2->current) {
|
||||||
node = ECORE_DLIST_NODE(list->current->next);
|
node = ECORE_DLIST_NODE(list->current->next);
|
||||||
|
@ -1246,7 +1246,7 @@ void *ecore_dlist_remove_first(Ecore_DList * list)
|
||||||
{
|
{
|
||||||
void *ret;
|
void *ret;
|
||||||
|
|
||||||
CHECK_PARAM_POINTER_RETURN("list", list, FALSE);
|
CHECK_PARAM_POINTER_RETURN("list", list, NULL);
|
||||||
|
|
||||||
ret = _ecore_dlist_remove_first(list);
|
ret = _ecore_dlist_remove_first(list);
|
||||||
|
|
||||||
|
@ -1281,7 +1281,7 @@ static void *_ecore_dlist_remove_first(Ecore_DList *list)
|
||||||
void *ret;
|
void *ret;
|
||||||
|
|
||||||
if (!list)
|
if (!list)
|
||||||
return FALSE;
|
return NULL;
|
||||||
|
|
||||||
ret = _ecore_list_remove_first(list);
|
ret = _ecore_list_remove_first(list);
|
||||||
if (ret && ECORE_LIST(list)->first)
|
if (ret && ECORE_LIST(list)->first)
|
||||||
|
@ -1300,7 +1300,7 @@ void *ecore_dlist_remove_last(Ecore_DList * list)
|
||||||
{
|
{
|
||||||
void *ret;
|
void *ret;
|
||||||
|
|
||||||
CHECK_PARAM_POINTER_RETURN("list", list, FALSE);
|
CHECK_PARAM_POINTER_RETURN("list", list, NULL);
|
||||||
|
|
||||||
ret = _ecore_list_remove_last(list);
|
ret = _ecore_list_remove_last(list);
|
||||||
|
|
||||||
|
@ -1317,7 +1317,7 @@ void *ecore_dlist_goto_index(Ecore_DList * list, int index)
|
||||||
{
|
{
|
||||||
void *ret;
|
void *ret;
|
||||||
|
|
||||||
CHECK_PARAM_POINTER_RETURN("list", list, FALSE);
|
CHECK_PARAM_POINTER_RETURN("list", list, NULL);
|
||||||
|
|
||||||
ret = _ecore_dlist_goto_index(list, index);
|
ret = _ecore_dlist_goto_index(list, index);
|
||||||
|
|
||||||
|
@ -1331,13 +1331,13 @@ static void *_ecore_dlist_goto_index(Ecore_DList *list, int index)
|
||||||
int i, increment;
|
int i, increment;
|
||||||
|
|
||||||
if (!list)
|
if (!list)
|
||||||
return FALSE;
|
return NULL;
|
||||||
|
|
||||||
if (ecore_list_is_empty(ECORE_LIST(list)))
|
if (ecore_list_is_empty(ECORE_LIST(list)))
|
||||||
return FALSE;
|
return NULL;
|
||||||
|
|
||||||
if (index > ecore_list_nodes(ECORE_LIST(list)) || index < 0)
|
if (index > ecore_list_nodes(ECORE_LIST(list)) || index < 0)
|
||||||
return FALSE;
|
return NULL;
|
||||||
|
|
||||||
if (ECORE_LIST(list)->index >= ECORE_LIST(list)->nodes)
|
if (ECORE_LIST(list)->index >= ECORE_LIST(list)->nodes)
|
||||||
_ecore_list_goto_last(ECORE_LIST(list));
|
_ecore_list_goto_last(ECORE_LIST(list));
|
||||||
|
@ -1368,7 +1368,7 @@ void *ecore_dlist_goto(Ecore_DList * list, void *data)
|
||||||
{
|
{
|
||||||
void *ret;
|
void *ret;
|
||||||
|
|
||||||
CHECK_PARAM_POINTER_RETURN("list", list, FALSE);
|
CHECK_PARAM_POINTER_RETURN("list", list, NULL);
|
||||||
|
|
||||||
ret = _ecore_list_goto(ECORE_LIST(list), data);
|
ret = _ecore_list_goto(ECORE_LIST(list), data);
|
||||||
|
|
||||||
|
@ -1385,7 +1385,7 @@ void *ecore_dlist_goto_first(Ecore_DList *list)
|
||||||
{
|
{
|
||||||
void *ret;
|
void *ret;
|
||||||
|
|
||||||
CHECK_PARAM_POINTER_RETURN("list", list, FALSE);
|
CHECK_PARAM_POINTER_RETURN("list", list, NULL);
|
||||||
|
|
||||||
ret = _ecore_list_goto_first(list);
|
ret = _ecore_list_goto_first(list);
|
||||||
|
|
||||||
|
@ -1401,7 +1401,7 @@ void *ecore_dlist_goto_last(Ecore_DList * list)
|
||||||
{
|
{
|
||||||
void *ret;
|
void *ret;
|
||||||
|
|
||||||
CHECK_PARAM_POINTER_RETURN("list", list, FALSE);
|
CHECK_PARAM_POINTER_RETURN("list", list, NULL);
|
||||||
|
|
||||||
ret = _ecore_list_goto_last(ECORE_LIST(list));
|
ret = _ecore_list_goto_last(ECORE_LIST(list));
|
||||||
|
|
||||||
|
|
|
@ -175,7 +175,7 @@ void *ecore_tree_node_value_get(Ecore_Tree_Node * node)
|
||||||
{
|
{
|
||||||
void *ret;
|
void *ret;
|
||||||
|
|
||||||
CHECK_PARAM_POINTER_RETURN("node", node, FALSE);
|
CHECK_PARAM_POINTER_RETURN("node", node, NULL);
|
||||||
ECORE_READ_LOCK(node);
|
ECORE_READ_LOCK(node);
|
||||||
ret = node->value;
|
ret = node->value;
|
||||||
ECORE_READ_UNLOCK(node);
|
ECORE_READ_UNLOCK(node);
|
||||||
|
@ -210,7 +210,7 @@ void *ecore_tree_node_key_get(Ecore_Tree_Node * node)
|
||||||
{
|
{
|
||||||
void *ret;
|
void *ret;
|
||||||
|
|
||||||
CHECK_PARAM_POINTER_RETURN("node", node, FALSE);
|
CHECK_PARAM_POINTER_RETURN("node", node, NULL);
|
||||||
ECORE_READ_LOCK(node);
|
ECORE_READ_LOCK(node);
|
||||||
ret = node->key;
|
ret = node->key;
|
||||||
ECORE_READ_UNLOCK(node);
|
ECORE_READ_UNLOCK(node);
|
||||||
|
@ -254,7 +254,7 @@ Ecore_Tree_Node *ecore_tree_get_node(Ecore_Tree * tree, void *key)
|
||||||
{
|
{
|
||||||
Ecore_Tree_Node *ret;
|
Ecore_Tree_Node *ret;
|
||||||
|
|
||||||
CHECK_PARAM_POINTER_RETURN("tree", tree, FALSE);
|
CHECK_PARAM_POINTER_RETURN("tree", tree, NULL);
|
||||||
|
|
||||||
ECORE_READ_LOCK(tree);
|
ECORE_READ_LOCK(tree);
|
||||||
ret = tree_node_find(tree, key);
|
ret = tree_node_find(tree, key);
|
||||||
|
@ -274,7 +274,7 @@ void *ecore_tree_get(Ecore_Tree * tree, void *key)
|
||||||
void *ret;
|
void *ret;
|
||||||
Ecore_Tree_Node *node;
|
Ecore_Tree_Node *node;
|
||||||
|
|
||||||
CHECK_PARAM_POINTER_RETURN("tree", tree, FALSE);
|
CHECK_PARAM_POINTER_RETURN("tree", tree, NULL);
|
||||||
|
|
||||||
ECORE_READ_LOCK(tree);
|
ECORE_READ_LOCK(tree);
|
||||||
node = tree_node_find(tree, key);
|
node = tree_node_find(tree, key);
|
||||||
|
@ -298,7 +298,7 @@ void *ecore_tree_get_closest_larger(Ecore_Tree * tree, void *key)
|
||||||
{
|
{
|
||||||
Ecore_Tree_Node *node;
|
Ecore_Tree_Node *node;
|
||||||
|
|
||||||
CHECK_PARAM_POINTER_RETURN("tree", tree, FALSE);
|
CHECK_PARAM_POINTER_RETURN("tree", tree, NULL);
|
||||||
|
|
||||||
ECORE_READ_LOCK(tree);
|
ECORE_READ_LOCK(tree);
|
||||||
node = tree_node_find(tree, key);
|
node = tree_node_find(tree, key);
|
||||||
|
@ -334,7 +334,7 @@ void *ecore_tree_get_closest_smaller(Ecore_Tree * tree, void *key)
|
||||||
{
|
{
|
||||||
Ecore_Tree_Node *node;
|
Ecore_Tree_Node *node;
|
||||||
|
|
||||||
CHECK_PARAM_POINTER_RETURN("tree", tree, FALSE);
|
CHECK_PARAM_POINTER_RETURN("tree", tree, NULL);
|
||||||
|
|
||||||
ECORE_READ_LOCK(tree);
|
ECORE_READ_LOCK(tree);
|
||||||
node = tree_node_find(tree, key);
|
node = tree_node_find(tree, key);
|
||||||
|
@ -614,7 +614,7 @@ Ecore_Tree_Node *tree_node_find_parent(Ecore_Tree * tree, void *key)
|
||||||
{
|
{
|
||||||
Ecore_Tree_Node *parent, *travel;
|
Ecore_Tree_Node *parent, *travel;
|
||||||
|
|
||||||
CHECK_PARAM_POINTER_RETURN("tree", tree, FALSE);
|
CHECK_PARAM_POINTER_RETURN("tree", tree, NULL);
|
||||||
|
|
||||||
parent = tree_node_find(tree, key);
|
parent = tree_node_find(tree, key);
|
||||||
if (parent)
|
if (parent)
|
||||||
|
@ -647,7 +647,7 @@ Ecore_Tree_Node *tree_node_find(Ecore_Tree * tree, void *key)
|
||||||
int compare;
|
int compare;
|
||||||
Ecore_Tree_Node *node;
|
Ecore_Tree_Node *node;
|
||||||
|
|
||||||
CHECK_PARAM_POINTER_RETURN("tree", tree, FALSE);
|
CHECK_PARAM_POINTER_RETURN("tree", tree, NULL);
|
||||||
|
|
||||||
node = tree->tree;
|
node = tree->tree;
|
||||||
while (node && (compare = tree->compare_func(key, node->key)) != 0) {
|
while (node && (compare = tree->compare_func(key, node->key)) != 0) {
|
||||||
|
|
Loading…
Reference in New Issue