/* create a new tree, talloc_free() to throw it away */
-struct sorted_tree *pathtree_init( void *data_p, int (cmp_fn)(void*, void*) );
+struct sorted_tree *pathtree_init(void *data_p);
/* add a new path component */
struct sorted_tree {
struct tree_node *root;
-
- /* not used currently (is it needed?) */
- int (*compare)(void* x, void *y);
};
/**************************************************************************
}
/**************************************************************************
- Initialize the tree's root. The cmp_fn is a callback function used
- for comparision of two children
+ Initialize the tree's root.
*************************************************************************/
-struct sorted_tree *pathtree_init( void *data_p, int (cmp_fn)(void*, void*) )
+struct sorted_tree *pathtree_init(void *data_p)
{
struct sorted_tree *tree = NULL;
return NULL;
}
- tree->compare = cmp_fn;
-
tree->root = talloc_zero(tree, struct tree_node);
if (tree->root == NULL) {
TALLOC_FREE( tree );