summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--volumes.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/volumes.h b/volumes.h
index f7761311..4ecb9931 100644
--- a/volumes.h
+++ b/volumes.h
@@ -156,7 +156,7 @@ struct map_lookup {
static inline int check_crossing_stripes(u64 start, u64 len)
{
return (start / BTRFS_STRIPE_LEN) !=
- ((start + len) / BTRFS_STRIPE_LEN);
+ ((start + len - 1) / BTRFS_STRIPE_LEN);
}
int __btrfs_map_block(struct btrfs_mapping_tree *map_tree, int rw,