[PATCH] Support for > 1 network connection
[fio.git] / filesetup.c
index 2af6c2fc560b99237b6ca24344f4a8c55426289c..610981b437594d32c90587178b323c2ce6dcc348 100644 (file)
@@ -107,7 +107,8 @@ static int create_files(struct thread_data *td)
                for_each_file(td, f, i) {
                        int file_there = !file_ok(td, f);
 
-                       if (file_there && td->ddir == WRITE && !td->overwrite) {
+                       if (file_there && td->ddir == DDIR_WRITE &&
+                           !td->overwrite) {
                                unlink(f->file_name);
                                file_there = 0;
                        }
@@ -329,6 +330,8 @@ static int setup_file(struct thread_data *td, struct fio_file *f)
 {
        int flags = 0;
 
+       if (td->io_ops->flags & FIO_NETIO)
+               return 0;
        if (td->odirect)
                flags |= OS_O_DIRECT;
        if (td->sync_io)