diff options
author | Chuck Lever <chuck.lever@oracle.com> | 2024-10-17 17:03:55 +0200 |
---|---|---|
committer | Chuck Lever <chuck.lever@oracle.com> | 2024-11-19 02:23:02 +0100 |
commit | 30c1d2411acd6d9d987f5f804aa173abb3b097ce (patch) | |
tree | 1053c83f3bc518c102e5ecf7785cbbe80f17dcf9 /fs/nfsd/nfs4xdr.c | |
parent | NFSD: Remove unused results in nfsd4_encode_pathname4() (diff) | |
download | linux-30c1d2411acd6d9d987f5f804aa173abb3b097ce.tar.xz linux-30c1d2411acd6d9d987f5f804aa173abb3b097ce.zip |
NFSD: Remove unused values from nfsd4_encode_components_esc()
Clean up. The computed value of @p is saved each time through the
loop but is never used.
Reviewed-by: Jeff Layton <jlayton@kernel.org>
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Diffstat (limited to '')
-rw-r--r-- | fs/nfsd/nfs4xdr.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/fs/nfsd/nfs4xdr.c b/fs/nfsd/nfs4xdr.c index a3a0d27e51e6..53fac037611c 100644 --- a/fs/nfsd/nfs4xdr.c +++ b/fs/nfsd/nfs4xdr.c @@ -2652,13 +2652,10 @@ static __be32 nfsd4_encode_components_esc(struct xdr_stream *xdr, char sep, strlen = end - str; if (strlen) { - p = xdr_reserve_space(xdr, strlen + 4); - if (!p) + if (xdr_stream_encode_opaque(xdr, str, strlen) < 0) return nfserr_resource; - p = xdr_encode_opaque(p, str, strlen); count++; - } - else + } else end++; if (found_esc) end = next; |