summaryrefslogtreecommitdiff
path: root/init.c
diff options
context:
space:
mode:
authorJens Axboe <axboe@kernel.dk>2018-09-07 12:57:52 -0600
committerJens Axboe <axboe@kernel.dk>2018-09-07 12:57:52 -0600
commitd5bb0a8902b787718e7027be85573773781f0898 (patch)
tree06180f644a918918ec9104e0dfc89a7099bb9562 /init.c
parent71ccdf58a51e339962db65dc8d875527cf795b00 (diff)
log: remember to free output buffer when done
We need to ensure we call buf_output_free() after using the temp storage, otherwise we leaked the memory that we allocated while filling the buffer. Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'init.c')
-rw-r--r--init.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/init.c b/init.c
index b13cee2..c235b05 100644
--- a/init.c
+++ b/init.c
@@ -1708,6 +1708,7 @@ static int add_job(struct thread_data *td, const char *jobname, int job_add_num,
__log_buf(&out, "ioengine=%s, iodepth=%u\n",
td->io_ops->name, o->iodepth);
log_info_buf(out.buf, out.buflen);
+ buf_output_free(&out);
free(c1);
free(c2);