From: Jens Axboe Date: Mon, 14 Apr 2014 19:09:04 +0000 (-0600) Subject: Avoid overwriting allocated pid_file X-Git-Tag: fio-2.1.9~30 X-Git-Url: https://git.kernel.dk/?a=commitdiff_plain;h=60c5ec73b9675dd2020210e0afac54aac0bf276c;p=fio.git Avoid overwriting allocated pid_file Signed-off-by: Jens Axboe --- diff --git a/init.c b/init.c index 8ed1de6f..fcc135e6 100644 --- a/init.c +++ b/init.c @@ -1938,6 +1938,8 @@ int parse_cmd_line(int argc, char *argv[], int client_type) backend = 1; break; case 'D': + if (optarg) + free(optarg); pid_file = strdup(optarg); break; case 'I':