linux-stable/fs/nfsd
Xiyu Yang e8cac2e306 nfsd: Fix svc_xprt refcnt leak when setup callback client failed
[ Upstream commit a4abc6b12e ]

nfsd4_process_cb_update() invokes svc_xprt_get(), which increases the
refcount of the "c->cn_xprt".

The reference counting issue happens in one exception handling path of
nfsd4_process_cb_update(). When setup callback client failed, the
function forgets to decrease the refcnt increased by svc_xprt_get(),
causing a refcnt leak.

Fix this issue by calling svc_xprt_put() when setup callback client
failed.

Signed-off-by: Xiyu Yang <xiyuyang19@fudan.edu.cn>
Signed-off-by: Xin Tan <tanxin.ctf@gmail.com>
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2020-06-24 17:50:17 +02:00
..
acl.h
auth.c
auth.h
blocklayout.c
blocklayoutxdr.c
blocklayoutxdr.h
cache.h
current_stateid.h
export.c
export.h
fault_inject.c
filecache.c nfsd: fix filecache lookup 2020-02-11 04:35:32 -08:00
filecache.h
flexfilelayout.c
flexfilelayoutxdr.c
flexfilelayoutxdr.h
idmap.h
Kconfig nfsd: depend on CRYPTO_MD5 for legacy client tracking 2020-01-26 10:01:01 +01:00
lockd.c
Makefile
netns.h
nfs2acl.c
nfs3acl.c
nfs3proc.c
nfs3xdr.c
nfs4acl.c
nfs4callback.c nfsd: Fix svc_xprt refcnt leak when setup callback client failed 2020-06-24 17:50:17 +02:00
nfs4idmap.c
nfs4layouts.c nfsd: fix delay timer on 32-bit architectures 2020-02-11 04:35:46 -08:00
nfs4proc.c NFSD fixing possible null pointer derefering in copy offload 2020-01-17 19:49:02 +01:00
nfs4recover.c nfsd: Fix cld_net->cn_tfm initialization 2020-01-17 19:48:47 +01:00
nfs4state.c nfsd: memory corruption in nfsd4_lock() 2020-05-02 08:48:46 +02:00
nfs4xdr.c
nfscache.c
nfsctl.c nfsd: fsnotify on rmdir under nfsd/clients/ 2020-04-17 10:50:20 +02:00
nfsd.h
nfsfh.c
nfsfh.h
nfsproc.c
nfssvc.c
nfsxdr.c
pnfs.h
state.h nfsd: fix jiffies/time_t mixup in LRU list 2020-02-11 04:35:47 -08:00
stats.c
stats.h
trace.c
trace.h
vfs.c nfsd: Clone should commit src file metadata too 2020-02-24 08:36:38 +01:00
vfs.h
xdr.h
xdr3.h
xdr4.h
xdr4cb.h