X-Git-Url: https://git.kernel.dk/?p=fio.git;a=blobdiff_plain;f=iolog.c;h=b72dcf9791cfa242ceace8b4080a03934e9fa554;hp=2f062892863cb9aa586baa9875fa06dfe30ba0cb;hb=66b182f90c3f08dcbd0592ce70cb350ca5ac0cc0;hpb=8ea203d36bf65f60ce16967d9cc9857c0778b216 diff --git a/iolog.c b/iolog.c index 2f062892..b72dcf97 100644 --- a/iolog.c +++ b/iolog.c @@ -634,18 +634,18 @@ static bool init_iolog_read(struct thread_data *td) return false; } - td->io_log_rfile = f; - /* * version 2 of the iolog stores a specific string as the * first line, check for that */ if (!strncmp(iolog_ver2, buffer, strlen(iolog_ver2))) { free_release_files(td); + td->io_log_rfile = f; return read_iolog2(td); } log_err("fio: iolog version 1 is no longer supported\n"); + fclose(f); return false; }