summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 31731ec)
raw | patch | inline | side by side (parent: 31731ec)
author | Florian Forster <octo@collectd.org> | |
Fri, 29 Sep 2017 06:44:22 +0000 (08:44 +0200) | ||
committer | Florian Forster <octo@collectd.org> | |
Fri, 29 Sep 2017 06:44:22 +0000 (08:44 +0200) |
src/dbi.c | patch | blob | history |
diff --git a/src/dbi.c b/src/dbi.c
index 8b383f17dc4edafbcfc0c45fa5b084ffe2be83ba..6043fe6724b17630ebc2b490e39d1a265c254b69 100644 (file)
--- a/src/dbi.c
+++ b/src/dbi.c
if (db->q_prep_areas)
for (size_t i = 0; i < db->queries_num; ++i)
udb_query_delete_preparation_area(db->q_prep_areas[i]);
- free(db->q_prep_areas);
+ sfree(db->q_prep_areas);
+ /* N.B.: db->queries references objects "owned" by the global queries
+ * variable. Free the array here, but not the content. */
+ sfree(db->queries);
sfree(db);
} /* }}} void cdbi_database_free */