]> git.ipfire.org Git - location/libloc.git/blobdiff - src/database.c
Merge branch 'perl'
[location/libloc.git] / src / database.c
index 648434565110f571461769ce8d2173a594c67d33..c41ce46aa7e5020bc2f3c28f9ca5ca9f5082db22 100644 (file)
@@ -323,7 +323,8 @@ static void loc_database_free(struct loc_database* db) {
                        ERROR(db->ctx, "Could not unmap network nodes section: %s\n", strerror(errno));
        }
 
-       loc_stringpool_unref(db->pool);
+       if (db->pool)
+               loc_stringpool_unref(db->pool);
 
        loc_unref(db->ctx);
        free(db);