forked from Minki/linux
NFSD: Clean up WRITE arg decoders
xdr_stream_subsegment() already returns a boolean value. Reviewed-by: Jeff Layton <jlayton@kernel.org> Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
This commit is contained in:
parent
c3d2a04f05
commit
d4da5baa53
@ -571,10 +571,8 @@ nfs3svc_decode_writeargs(struct svc_rqst *rqstp, struct xdr_stream *xdr)
|
||||
args->count = max_blocksize;
|
||||
args->len = max_blocksize;
|
||||
}
|
||||
if (!xdr_stream_subsegment(xdr, &args->payload, args->count))
|
||||
return false;
|
||||
|
||||
return true;
|
||||
return xdr_stream_subsegment(xdr, &args->payload, args->count);
|
||||
}
|
||||
|
||||
bool
|
||||
|
@ -338,10 +338,8 @@ nfssvc_decode_writeargs(struct svc_rqst *rqstp, struct xdr_stream *xdr)
|
||||
return false;
|
||||
if (args->len > NFSSVC_MAXBLKSIZE_V2)
|
||||
return false;
|
||||
if (!xdr_stream_subsegment(xdr, &args->payload, args->len))
|
||||
return false;
|
||||
|
||||
return true;
|
||||
return xdr_stream_subsegment(xdr, &args->payload, args->len);
|
||||
}
|
||||
|
||||
bool
|
||||
|
Loading…
Reference in New Issue
Block a user