#include "../smalloc.h"
#include "../minmax.h"
#include "../crc/md5.h"
-#include "../memalign.h"
+#include "../lib/memalign.h"
#include "../os/os.h"
#include "../gettime.h"
#include "../fio_time.h"
for (i = 0; i < nblocks; i++) {
void *thisptr = buf + (i * blocksize);
- if (items)
- items[i].offset = offset;
+ items[i].offset = offset;
crc_buf(thisptr, items[i].hash);
offset += blocksize;
nitems++;
threads = malloc(num_threads * sizeof(struct worker_thread));
for (i = 0; i < num_threads; i++) {
+ memset(&threads[i], 0, sizeof(struct worker_thread));
threads[i].fd = f->fd;
- threads[i].items = 0;
- threads[i].err = 0;
- threads[i].done = 0;
err = pthread_create(&threads[i].thread, NULL, thread_fn, &threads[i]);
if (err) {