X-Git-Url: http://erislabs.net/gitweb/?a=blobdiff_plain;f=lib%2Fgl_rbtree_oset.c;h=5e74fc727e858ba115996145a18e80e20e9027c8;hb=53ed71f6a1cc4207b1972b73e4b5e1e830c8119d;hp=2ca4fbccdaf7e3410b0a3563688c8203fac8f7d9;hpb=d96695ef5092764e7839ecc3644276f4c324ba6b;p=gnulib.git diff --git a/lib/gl_rbtree_oset.c b/lib/gl_rbtree_oset.c index 2ca4fbccd..5e74fc727 100644 --- a/lib/gl_rbtree_oset.c +++ b/lib/gl_rbtree_oset.c @@ -16,9 +16,7 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -#ifdef HAVE_CONFIG_H -# include -#endif +#include /* Specification. */ #include "gl_rbtree_oset.h" @@ -544,8 +542,7 @@ static gl_oset_node_t gl_tree_add_first (gl_oset_t set, const void *elt) { /* Create new node. */ - gl_oset_node_t new_node = - (struct gl_oset_node_impl *) xmalloc (sizeof (struct gl_oset_node_impl)); + gl_oset_node_t new_node = XMALLOC (struct gl_oset_node_impl); new_node->left = NULL; new_node->right = NULL; @@ -580,8 +577,7 @@ static gl_oset_node_t gl_tree_add_before (gl_oset_t set, gl_oset_node_t node, const void *elt) { /* Create new node. */ - gl_oset_node_t new_node = - (struct gl_oset_node_impl *) xmalloc (sizeof (struct gl_oset_node_impl)); + gl_oset_node_t new_node = XMALLOC (struct gl_oset_node_impl); new_node->left = NULL; new_node->right = NULL; @@ -609,8 +605,7 @@ static gl_oset_node_t gl_tree_add_after (gl_oset_t set, gl_oset_node_t node, const void *elt) { /* Create new node. */ - gl_oset_node_t new_node = - (struct gl_oset_node_impl *) xmalloc (sizeof (struct gl_oset_node_impl)); + gl_oset_node_t new_node = XMALLOC (struct gl_oset_node_impl); new_node->left = NULL; new_node->right = NULL; @@ -798,6 +793,7 @@ const struct gl_oset_implementation gl_rbtree_oset_implementation = gl_tree_create_empty, gl_tree_size, gl_tree_search, + gl_tree_search_atleast, gl_tree_add, gl_tree_remove, gl_tree_oset_free,