X-Git-Url: https://git.kernel.dk/?p=fio.git;a=blobdiff_plain;f=iolog.c;h=1d61ba23ac3ba82b6334ad45dc0a16aee7babd49;hp=f962864d912d9b5cdc3bfbc39286241fdd717665;hb=0c4ce7ce9ce7fa0d644020816feefdf9c3a64a4e;hpb=ac9b9101f1ef57965d6ffd51f143274a1eb665ef diff --git a/iolog.c b/iolog.c index f962864d..1d61ba23 100644 --- a/iolog.c +++ b/iolog.c @@ -492,13 +492,15 @@ int init_iolog(struct thread_data *td) return ret; } -void setup_log(struct io_log **log) +void setup_log(struct io_log **log, unsigned long avg_msec) { struct io_log *l = malloc(sizeof(*l)); + memset(l, 0, sizeof(*l)); l->nr_samples = 0; l->max_samples = 1024; l->log = malloc(l->max_samples * sizeof(struct io_sample)); + l->avg_msec = avg_msec; *log = l; }