Make file structures dynamically allocated
[fio.git] / fio.h
diff --git a/fio.h b/fio.h
index 92819349dabedde6c95d69d8f843edb1a1078d11..ca35ffcd5e7884c8fce02f9ad741b45bb8a67e10 100644 (file)
--- a/fio.h
+++ b/fio.h
@@ -498,7 +498,7 @@ struct thread_data {
        int thread_number;
        int groupid;
        struct thread_stat ts;
-       struct fio_file *files;
+       struct fio_file **files;
        unsigned int files_index;
        unsigned int nr_open_files;
        unsigned int nr_done_files;
@@ -941,7 +941,7 @@ extern void close_ioengine(struct thread_data *);
 #define for_each_td(td, i)     \
        for ((i) = 0, (td) = &threads[0]; (i) < (int) thread_number; (i)++, (td)++)
 #define for_each_file(td, f, i)        \
-       for ((i) = 0, (f) = &(td)->files[0]; (i) < (td)->o.nr_files; (i)++, (f)++)
+       for ((i) = 0, (f) = (td)->files[0]; (i) < (td)->o.nr_files; (i)++, (f)++)
 
 #define fio_assert(td, cond)   do {    \
        if (!(cond)) {                  \