projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
55b6e77
)
nfs: fix unchecked value
author
Roman Borisov
<
[email protected]
>
Wed, 13 Oct 2010 12:54:51 +0000
(16:54 +0400)
committer
Trond Myklebust
<
[email protected]
>
Sun, 24 Oct 2010 22:00:12 +0000
(18:00 -0400)
Return value of "decode_attr_bitmap()" was not checked;
Signed-off-by: Roman Borisov <
[email protected]
>
Signed-off-by: Trond Myklebust <
[email protected]
>
fs/nfs/nfs4xdr.c
patch
|
blob
|
history
diff --git
a/fs/nfs/nfs4xdr.c
b/fs/nfs/nfs4xdr.c
index 7131c761d85cecbb00727f046633ac05deeaf95e..bd2101d918c80cda6d6f21b03f696e5312803676 100644
(file)
--- a/
fs/nfs/nfs4xdr.c
+++ b/
fs/nfs/nfs4xdr.c
@@
-2687,7
+2687,10
@@
out_overflow:
static int decode_attr_supported(struct xdr_stream *xdr, uint32_t *bitmap, uint32_t *bitmask)
{
if (likely(bitmap[0] & FATTR4_WORD0_SUPPORTED_ATTRS)) {
- decode_attr_bitmap(xdr, bitmask);
+ int ret;
+ ret = decode_attr_bitmap(xdr, bitmask);
+ if (unlikely(ret < 0))
+ return ret;
bitmap[0] &= ~FATTR4_WORD0_SUPPORTED_ATTRS;
} else
bitmask[0] = bitmask[1] = 0;