summaryrefslogtreecommitdiffstats
path: root/zix
diff options
context:
space:
mode:
Diffstat (limited to 'zix')
-rw-r--r--zix/btree.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/zix/btree.c b/zix/btree.c
index 0300523..c81b283 100644
--- a/zix/btree.c
+++ b/zix/btree.c
@@ -661,6 +661,9 @@ zix_btree_lower_bound(const ZixBTree* const t,
if (!t) {
*ti = NULL;
return ZIX_STATUS_BAD_ARG;
+ } else if (!t->root) {
+ *ti = NULL;
+ return ZIX_STATUS_SUCCESS;
}
ZixBTreeNode* n = t->root;