Release NMEM when config cant be read
[pazpar2-moved-to-github.git] / src / pazpar2_config.c
index 197b696..9456f86 100644 (file)
@@ -886,6 +886,7 @@ struct conf_config *config_create(const char *fname, int verbose)
     if (!doc)
     {
         yaz_log(YLOG_FATAL, "Failed to read %s", fname);
+        nmem_destroy(nmem);
         return 0;
     }