X-Git-Url: https://git.verplant.org/?a=blobdiff_plain;f=src%2Fcurl_json.c;h=3ba55603d329342e6a30fa86b6908531e3e36e73;hb=26314b8c3fb08e1f0017ee9a6277b7fe370bf2a0;hp=1c225f79cec84de3e155e825e9367f6f5e405ab4;hpb=0003c4d3c184f0f437499d6073cd023dc7b659c2;p=collectd.git diff --git a/src/curl_json.c b/src/curl_json.c index 1c225f79..3ba55603 100644 --- a/src/curl_json.c +++ b/src/curl_json.c @@ -503,6 +503,7 @@ static int cj_config_add_key (cj_t *db, /* {{{ */ { ERROR ("curl_json plugin: cj_config: " "Invalid key: %s", ci->key); + cj_key_free (key); return (-1); } @@ -696,6 +697,7 @@ static int cj_config_add_url (oconfig_item_t *ci) /* {{{ */ { ERROR ("curl_json plugin: cj_config: " "Invalid key: %s", ci->key); + cj_free (db); return (-1); } if (status != 0)