aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--fs/nfsd/nfs4xdr.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/fs/nfsd/nfs4xdr.c b/fs/nfsd/nfs4xdr.c
index 1ad7bd4e346f..01023a595163 100644
--- a/fs/nfsd/nfs4xdr.c
+++ b/fs/nfsd/nfs4xdr.c
@@ -3072,11 +3072,8 @@ static __be32 nfsd4_encode_splice_read(
3072 __be32 nfserr; 3072 __be32 nfserr;
3073 __be32 *p = xdr->p - 2; 3073 __be32 *p = xdr->p - 2;
3074 3074
3075 /* 3075 /* Make sure there will be room for padding if needed */
3076 * Don't inline pages unless we know there's room for eof, 3076 if (xdr->end - xdr->p < 1)
3077 * count, and possible padding:
3078 */
3079 if (xdr->end - xdr->p < 3)
3080 return nfserr_resource; 3077 return nfserr_resource;
3081 3078
3082 nfserr = nfsd_splice_read(read->rd_rqstp, file, 3079 nfserr = nfsd_splice_read(read->rd_rqstp, file,