stat: fix segfault with fio option --bandwidth-log
The log_params for aggregate read, write and trim only specify
log type. As a result the io_log doesn't have the relevant
thread_data structure. With fio option --bandwidth-log this results
in segmentation fault.
Add a check and use DEF_LOG_ENTRIES for such case.
Fixes:
0a852a50 ("fio: Introduce the log_entries option")
Signed-off-by: Ankit Kumar <ankit.kumar@samsung.com>
[vkf: added Fixes tag, lightly edited commit message]
Signed-off-by: Vincent Fu <vincent.fu@samsung.com>