Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 361960
b: refs/heads/master
c: 82d130f
h: refs/heads/master
v: v3
  • Loading branch information
Miao Xie authored and Josef Bacik committed Mar 28, 2013
1 parent 7281598 commit 4f8e938
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 39847c4d3d91f487f9ab3d083ee5d0f8419f105c
refs/heads/master: 82d130ff390be67d980d8b6f39e921c0b1d8d8e0
4 changes: 3 additions & 1 deletion trunk/fs/btrfs/file-item.c
Original file line number Diff line number Diff line change
Expand Up @@ -118,9 +118,11 @@ struct btrfs_csum_item *btrfs_lookup_csum(struct btrfs_trans_handle *trans,
csums_in_item = btrfs_item_size_nr(leaf, path->slots[0]);
csums_in_item /= csum_size;

if (csum_offset >= csums_in_item) {
if (csum_offset == csums_in_item) {
ret = -EFBIG;
goto fail;
} else if (csum_offset > csums_in_item) {
goto fail;
}
}
item = btrfs_item_ptr(leaf, path->slots[0], struct btrfs_csum_item);
Expand Down

0 comments on commit 4f8e938

Please sign in to comment.