diff options
author | Romain Forlot <romain.forlot@iot.bzh> | 2018-05-16 00:37:34 +0200 |
---|---|---|
committer | Sebastien Douheret <sebastien.douheret@iot.bzh> | 2018-07-10 23:41:14 +0200 |
commit | c8d0593d6495e87603806ada76a399500cdc2831 (patch) | |
tree | d0d9dc88a43ab30a3712a7946d21baea837bebfb /src/harvester.c | |
parent | 4f40dc104633e44d3b021fafb1057b7669616926 (diff) |
Fix memory leak and avoid compile warning
Change-Id: Ib0bcba9daad456f63c0ea704e1fa87f44b6acc98
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
Diffstat (limited to 'src/harvester.c')
-rw-r--r-- | src/harvester.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/harvester.c b/src/harvester.c index 30ba486..1d4d9a6 100644 --- a/src/harvester.c +++ b/src/harvester.c @@ -48,9 +48,9 @@ void afv_write(struct afb_req req) *metric = NULL; if(wrap_json_unpack(req_args, "{s?s,s?o,so!}", - "host", &host, - "port", &portJ, - "metric", &metric) || ! metric) + "host", &host, + "port", &portJ, + "metric", &metric) || ! metric) afb_req_fail(req, "Failed", "Error processing arguments. Miss metric\ JSON object or malformed"); else { @@ -82,10 +82,10 @@ int init() case INFLUX: tsdb_write = influxdb_write; write_curl_cb = influxdb_write_curl_cb; - if(influxdb_reader(&r_args) != 0) { + /*if(influxdb_reader(&r_args) != 0) { AFB_ERROR("Problem initiating reader timer. Abort"); return ERROR; - } + }*/ break; default: AFB_ERROR("No Time Series Database found. Abort"); |