summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/lib.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lib.c b/src/lib.c
index bc5a62a..b538c00 100644
--- a/src/lib.c
+++ b/src/lib.c
@@ -101,7 +101,7 @@ lilv_lib_close(LilvLib* lib)
dlclose(lib->lib);
ZixTreeIter* i = NULL;
- if (!zix_tree_find(lib->world->libs, lib, &i)) {
+ if (lib->world->libs && !zix_tree_find(lib->world->libs, lib, &i)) {
zix_tree_remove(lib->world->libs, i);
}