projects
/
fio.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
cb1402d
)
Fix crash with --debug=file and NULL file return
author
Jens Axboe
<axboe@fb.com>
Tue, 25 Feb 2014 21:43:17 +0000
(13:43 -0800)
committer
Jens Axboe
<axboe@fb.com>
Tue, 25 Feb 2014 21:43:17 +0000
(13:43 -0800)
Don't attempt to dereference that, obviously.
Signed-off-by: Jens Axboe <axboe@fb.com>
io_u.c
patch
|
blob
|
blame
|
history
diff --git
a/io_u.c
b/io_u.c
index 619fa25255f84ee785eccedcf7f96bfe94b41ab4..a69efb76c2d727cd3f5e883382270f4a3d53cc14 100644
(file)
--- a/
io_u.c
+++ b/
io_u.c
@@
-1093,7
+1093,10
@@
static struct fio_file *__get_next_file(struct thread_data *td)
td->file_service_file = f;
td->file_service_left = td->file_service_nr - 1;
out:
- dprint(FD_FILE, "get_next_file: %p [%s]\n", f, f->file_name);
+ if (f)
+ dprint(FD_FILE, "get_next_file: %p [%s]\n", f, f->file_name);
+ else
+ dprint(FD_FILE, "get_next_file: NULL\n");
return f;
}