Add a recursive tree freeing function.

This commit is contained in:
2018-02-17 19:20:10 -08:00
parent a52735f0b3
commit 811704be25
3 changed files with 35 additions and 11 deletions

View File

@@ -80,5 +80,12 @@ typedef struct libab_tree_s libab_tree;
* @param tree the tree to free.
*/
void libab_tree_free(libab_tree* tree);
/**
* Frees the given tree recursively,
* deleting the children first and the moving on
* to the parents.
* @param tree the tree to free.
*/
void libab_tree_free_recursive(libab_tree* tree);
#endif