Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 273764
b: refs/heads/master
c: e414966
h: refs/heads/master
v: v3
  • Loading branch information
Chuck Lever authored and Trond Myklebust committed Oct 31, 2011
1 parent 90cd5e4 commit dcd5050
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 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: c6e696660213a89a5bfde8b49d539553904c808f
refs/heads/master: e414966b81a74745ac8d6bfeda0d95fb721e6d91
7 changes: 3 additions & 4 deletions trunk/fs/nfs/nfs4filelayout.c
Original file line number Diff line number Diff line change
Expand Up @@ -449,9 +449,8 @@ filelayout_check_layout(struct pnfs_layout_hdr *lo,

fl->dsaddr = dsaddr;

if (fl->first_stripe_index < 0 ||
fl->first_stripe_index >= dsaddr->stripe_count) {
dprintk("%s Bad first_stripe_index %d\n",
if (fl->first_stripe_index >= dsaddr->stripe_count) {
dprintk("%s Bad first_stripe_index %u\n",
__func__, fl->first_stripe_index);
goto out_put;
}
Expand Down Expand Up @@ -552,7 +551,7 @@ filelayout_decode_layout(struct pnfs_layout_hdr *flo,

/* Note that a zero value for num_fh is legal for STRIPE_SPARSE.
* Futher checking is done in filelayout_check_layout */
if (fl->num_fh < 0 || fl->num_fh >
if (fl->num_fh >
max(NFS4_PNFS_MAX_STRIPE_CNT, NFS4_PNFS_MAX_MULTI_CNT))
goto out_err;

Expand Down

0 comments on commit dcd5050

Please sign in to comment.