Make file structures dynamically allocated
[fio.git] / log.c
diff --git a/log.c b/log.c
index 8754eb051a1ecfb3ba38290b8d88d5a6bb547c8a..f6fbaeb26c7e1c023055ada3252bf59201cc32c1 100644 (file)
--- a/log.c
+++ b/log.c
@@ -65,7 +65,7 @@ int read_iolog_get(struct thread_data *td, struct io_u *io_u)
                 * invalid ddir, this is a file action
                 */
                if (ipo->ddir == DDIR_INVAL) {
                 * invalid ddir, this is a file action
                 */
                if (ipo->ddir == DDIR_INVAL) {
-                       struct fio_file *f = &td->files[ipo->fileno];
+                       struct fio_file *f = td->files[ipo->fileno];
 
                        if (ipo->file_action == FIO_LOG_OPEN_FILE) {
                                assert(!td_io_open_file(td, f));
 
                        if (ipo->file_action == FIO_LOG_OPEN_FILE) {
                                assert(!td_io_open_file(td, f));
@@ -81,7 +81,7 @@ int read_iolog_get(struct thread_data *td, struct io_u *io_u)
                io_u->offset = ipo->offset;
                io_u->buflen = ipo->len;
                io_u->ddir = ipo->ddir;
                io_u->offset = ipo->offset;
                io_u->buflen = ipo->len;
                io_u->ddir = ipo->ddir;
-               io_u->file = &td->files[ipo->fileno];
+               io_u->file = td->files[ipo->fileno];
                get_file(io_u->file);
 
                dprint(FD_IO, "iolog: get %llu/%lu/%s\n", io_u->offset,
                get_file(io_u->file);
 
                dprint(FD_IO, "iolog: get %llu/%lu/%s\n", io_u->offset,