Windows: add install directory to the Path environment variable
[fio.git] / io_u.c
diff --git a/io_u.c b/io_u.c
index 77557dfdca12748f1db2249c05efc93a21b09f4b..75b23eb47d9091c58d3df19b2f6def826d3c3836 100644 (file)
--- a/io_u.c
+++ b/io_u.c
@@ -104,7 +104,7 @@ static int __get_next_rand_offset(struct thread_data *td, struct fio_file *f,
 
                dprint(FD_RANDOM, "off rand %llu\n", (unsigned long long) r);
 
-               *b = (lastb - 1) * (r / ((uint64_t) rmax + 1.0));
+               *b = lastb * (r / ((uint64_t) rmax + 1.0));
        } else {
                uint64_t off = 0;