diff options
author | David S. Miller <davem@davemloft.net> | 2018-08-02 20:55:32 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2018-08-02 20:55:32 +0300 |
commit | 89b1698c93a9dee043154f33d96bca9964e705f1 (patch) | |
tree | dd9dcb1965baae8edcf0b496aaa6a70609b6fc11 /fs/xfs/libxfs/xfs_alloc.c | |
parent | ffd7ce3cd9c294f1ff49ec02cdbd1bc7cb913db6 (diff) | |
parent | e30cb13c5a09ff5f043a6570c32e49b063bea6a1 (diff) | |
download | linux-89b1698c93a9dee043154f33d96bca9964e705f1.tar.xz |
Merge ra.kernel.org:/pub/scm/linux/kernel/git/davem/net
The BTF conflicts were simple overlapping changes.
The virtio_net conflict was an overlap of a fix of statistics counter,
happening alongisde a move over to a bonafide statistics structure
rather than counting value on the stack.
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'fs/xfs/libxfs/xfs_alloc.c')
-rw-r--r-- | fs/xfs/libxfs/xfs_alloc.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/fs/xfs/libxfs/xfs_alloc.c b/fs/xfs/libxfs/xfs_alloc.c index eef466260d43..75dbdc14c45f 100644 --- a/fs/xfs/libxfs/xfs_alloc.c +++ b/fs/xfs/libxfs/xfs_alloc.c @@ -223,12 +223,13 @@ xfs_alloc_get_rec( error = xfs_btree_get_rec(cur, &rec, stat); if (error || !(*stat)) return error; - if (rec->alloc.ar_blockcount == 0) - goto out_bad_rec; *bno = be32_to_cpu(rec->alloc.ar_startblock); *len = be32_to_cpu(rec->alloc.ar_blockcount); + if (*len == 0) + goto out_bad_rec; + /* check for valid extent range, including overflow */ if (!xfs_verify_agbno(mp, agno, *bno)) goto out_bad_rec; |