Thread (138 messages) 138 messages, 9 authors, 2016-10-10
STALE3551d

[PATCH 4.4 014/118] NFSv4.x: Fix a refcount leak in nfs_callback_up_net

From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Date: 2016-09-22 17:32:58
Also in: lkml

4.4-stable review patch.  If anyone has any objections, please let me know.

------------------

From: Trond Myklebust <redacted>

commit 98b0f80c2396224bbbed81792b526e6c72ba9efa upstream.

On error, the callers expect us to return without bumping
nn->cb_users[].

Signed-off-by: Trond Myklebust <redacted>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

---
 fs/nfs/callback.c |    1 +
 1 file changed, 1 insertion(+)
--- a/fs/nfs/callback.c
+++ b/fs/nfs/callback.c
@@ -275,6 +275,7 @@ static int nfs_callback_up_net(int minor
 err_socks:
 	svc_rpcb_cleanup(serv, net);
 err_bind:
+	nn->cb_users[minorversion]--;
 	dprintk("NFS: Couldn't create callback socket: err = %d; "
 			"net = %p\n", ret, net);
 	return ret;

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help