list.c
/* Move to the next/previous node depending on direction*/
Move to the next/previous node depending on direction
Move to the next / previous node depending on direction
void * list_iter_next(list_iter_t *iter) 
{
	iter->prev = iter->next;
	if (iter->next != NULL) iter->next = iter->direction == FORWARD 
									? list_node_get_next(iter->next)
									: list_node_get_prev(iter->next);
	return iter->prev != NULL ? list_node_get_data(iter->prev): NULL;
}
void * list_iter_next ( list_iter_t * iter ) { iter -> prev = iter -> next ; if ( iter -> next != NULL ) iter -> next = iter -> direction == FORWARD ? list_node_get_next ( iter -> next ) : list_node_get_prev ( iter -> next ) ; return iter -> prev != NULL ? list_node_get_data ( iter -> prev ) : NULL ; }
Move to the next/previous node depending on direction
Move to the next / previous node depending on direction