diff options
author | Neil Brown <neilb@suse.de> | 2005-08-26 02:26:37 +0000 |
---|---|---|
committer | Neil Brown <neilb@suse.de> | 2005-08-26 02:26:37 +0000 |
commit | 8431b2b2861d08b517468ae0f3ce2e3502d5ea94 (patch) | |
tree | ccaff89b6c18e2fa26339fef944333ebe47b81e4 /bitmap.c | |
parent | 34355de9ca799376d1ed44142c2c5fe8471fe30c (diff) | |
download | mdadm-8431b2b2861d08b517468ae0f3ce2e3502d5ea94.tar.gz |
Getting ready for 2.0 release...
Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au>
Diffstat (limited to 'bitmap.c')
-rw-r--r-- | bitmap.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -152,11 +152,11 @@ bitmap_info_t *bitmap_fd_read(int fd, int brief) */ total_bits = bitmap_bits(info->sb.sync_size, info->sb.chunksize); - while ((n = read(fd, buf, sizeof(*buf))) > 0) { + while ((n = read(fd, buf, sizeof(buf))) > 0) { unsigned long long remaining = total_bits - read_bits; - if (remaining > sizeof(*buf) * 8) /* we want the full buffer */ - remaining = sizeof(*buf) * 8; + if (remaining > sizeof(buf) * 8) /* we want the full buffer */ + remaining = sizeof(buf) * 8; if (remaining > n * 8) /* the file is truncated */ remaining = n * 8; dirty_bits += count_dirty_bits(buf, remaining); |