bitset: Fix large runs

This commit is contained in:
nick
2013-07-24 17:42:08 +01:00
parent 5c59a412af
commit bed8959d47
5 changed files with 31 additions and 7 deletions

View File

@@ -140,7 +140,7 @@ void write_not_zeroes(struct client* client, uint64_t from, uint64_t len)
char zerobuffer[block_allocation_resolution];
/* not allocated, read in block_allocation_resoution */
while (run > 0) {
int blockrun = block_allocation_resolution -
uint64_t blockrun = block_allocation_resolution -
(from % block_allocation_resolution);
if (blockrun > run)
blockrun = run;