diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2012-04-13 21:49:47 +0400 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2012-04-13 21:50:52 +0400 |
commit | e847469bf77a1d339274074ed068d461f0c872bc (patch) | |
tree | 4e5e9b3fea923432d6745ed1369100d2b941af0d /fs/lockd/clntxdr.c | |
parent | 72094e43e3af5020510f920321d71f1798fa896d (diff) | |
download | linux-e847469bf77a1d339274074ed068d461f0c872bc.tar.xz |
lockd: fix the endianness bug
comparing be32 values for < is not doing the right thing...
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/lockd/clntxdr.c')
-rw-r--r-- | fs/lockd/clntxdr.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/lockd/clntxdr.c b/fs/lockd/clntxdr.c index 3d35e3e80c1c..d269ada7670e 100644 --- a/fs/lockd/clntxdr.c +++ b/fs/lockd/clntxdr.c @@ -236,7 +236,7 @@ static int decode_nlm_stat(struct xdr_stream *xdr, p = xdr_inline_decode(xdr, 4); if (unlikely(p == NULL)) goto out_overflow; - if (unlikely(*p > nlm_lck_denied_grace_period)) + if (unlikely(ntohl(*p) > ntohl(nlm_lck_denied_grace_period))) goto out_enum; *stat = *p; return 0; |