stat: Fix another memory leak in add_ddir_status_json()
[fio.git] / io_u.c
diff --git a/io_u.c b/io_u.c
index 5cbbe85a4180f3d5f8cac1c7d4047fed7961d459..03f5c21f37c10523362ed2c73af8f57fe1ca691e 100644 (file)
--- a/io_u.c
+++ b/io_u.c
@@ -644,7 +644,7 @@ static enum fio_ddir rate_ddir(struct thread_data *td, enum fio_ddir ddir)
        uint64_t now;
 
        assert(ddir_rw(ddir));
-       now = utime_since_now(&td->start);
+       now = utime_since_now(&td->epoch);
 
        /*
         * if rate_next_io_time is in the past, need to catch up to rate
@@ -850,8 +850,7 @@ static void setup_strided_zone_mode(struct thread_data *td, struct io_u *io_u)
        /*
         * See if it's time to switch to a new zone
         */
-       if (td->zone_bytes >= td->o.zone_size &&
-                       fio_option_is_set(&td->o, zone_skip)) {
+       if (td->zone_bytes >= td->o.zone_size) {
                td->zone_bytes = 0;
                f->file_offset += td->o.zone_range + td->o.zone_skip;
 
@@ -2183,7 +2182,7 @@ void io_u_fill_buffer(struct thread_data *td, struct io_u *io_u,
 static int do_sync_file_range(const struct thread_data *td,
                              struct fio_file *f)
 {
-       off64_t offset, nbytes;
+       uint64_t offset, nbytes;
 
        offset = f->first_write;
        nbytes = f->last_write - f->first_write;