summaryrefslogtreecommitdiffstats
path: root/libnetdata
diff options
context:
space:
mode:
authorVladimir Kobal <vlad@prokk.net>2020-02-01 00:05:45 +0200
committerGitHub <noreply@github.com>2020-02-01 00:05:45 +0200
commit177af26ea878e673166ebbeb4518539f624a81f0 (patch)
tree9f874527a1e6e25c85a05d62b3623e6d8b5f79fd /libnetdata
parent43bc627b1dc2e667ad2e6e8a0c2ff1e0b512dcdf (diff)
Parse host tags (#7702)
* Fix memory leaks * Check for configuration options * Parse simple tags * Parse JSON tags * Remove an unnecessary check * Parse a JSON object * Parse a JSON array * Update the documentation * Fix host locks
Diffstat (limited to 'libnetdata')
-rw-r--r--libnetdata/config/appconfig.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/libnetdata/config/appconfig.c b/libnetdata/config/appconfig.c
index 31225336ee..c77cf34ec3 100644
--- a/libnetdata/config/appconfig.c
+++ b/libnetdata/config/appconfig.c
@@ -566,7 +566,9 @@ int appconfig_load(struct config *root, char *filename, int overwrite_used, cons
error("INTERNAL ERROR: Cannot remove '%s' from section '%s', it was not inserted before.",
cv2->name, co->name);
- free(cv2);
+ freez(cv2->name);
+ freez(cv2->value);
+ freez(cv2);
cv2 = save;
}
co->values = NULL;