From 6673846481067bded4fba3bb00d927aee7d542bb Mon Sep 17 00:00:00 2001 From: Simeon Miteff Date: Thu, 29 Sep 2022 09:38:07 +1000 Subject: [PATCH] profiling: Make rule_perf.log JSON output newline-delimited Adding a newline makes the output valid JSON when multiple sortings of the rules profile object are written to the log. --- src/util-profiling-rules.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/util-profiling-rules.c b/src/util-profiling-rules.c index 2303a513265b..c221de6901f3 100644 --- a/src/util-profiling-rules.c +++ b/src/util-profiling-rules.c @@ -340,7 +340,7 @@ static void DumpJson(FILE *fp, SCProfileSummary *summary, if (unlikely(js_s == NULL)) return; - fprintf(fp, "%s", js_s); + fprintf(fp, "%s\n", js_s); free(js_s); json_decref(js); }