diff options
author | Andrejs Aire <git-no-reply@zabbix.com> | 2019-02-15 13:11:31 +0300 |
---|---|---|
committer | Andrejs Aire <git-no-reply@zabbix.com> | 2019-02-15 13:11:31 +0300 |
commit | d06b9de4522fda5656c143eb99c4ab3b8d642c74 (patch) | |
tree | 352c4b23d057bf6c021ebc22649a13cc8eefbabd /src | |
parent | 2dd94924fda60c5b7457040f0a71e17adc74ffb8 (diff) |
.......... [ZBXNEXT-4865] fixed "line_raw" JSON output
Diffstat (limited to 'src')
-rw-r--r-- | src/libs/zbxprometheus/zbxprometheus.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/libs/zbxprometheus/zbxprometheus.c b/src/libs/zbxprometheus/zbxprometheus.c index 27cfe917cd2..1e70ffc70a0 100644 --- a/src/libs/zbxprometheus/zbxprometheus.c +++ b/src/libs/zbxprometheus/zbxprometheus.c @@ -334,7 +334,7 @@ static int zbx_prometh_output_metric_json(struct zbx_prometh_metric *m, char **b } zbx_snprintf(tmp, sizeof(tmp), ZBX_PROMETH_JSON_INDENT2 "\"value\": \"%s\",\n" - ZBX_PROMETH_JSON_INDENT2 "\"line_raw\": \"%s\",\n", + ZBX_PROMETH_JSON_INDENT2 "\"line_raw\": \"%s\"\n", m->value, m->line_raw); offset = zbx_prometh_json_copy_to_outbuf(tmp, buf, offset); @@ -691,7 +691,7 @@ static void zbx_prometh_data_prepare(zbx_prometh_list_t *in_data, const char *st zbx_prometh_list_append_elem(&metrics, (void *)new_metric); - free(c); + zbx_free(c); str = p; /* next metric string */ } |