[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <lsq.1554212308.915466377@decadent.org.uk>
Date: Tue, 02 Apr 2019 14:38:28 +0100
From: Ben Hutchings <ben@...adent.org.uk>
To: linux-kernel@...r.kernel.org, stable@...r.kernel.org
CC: akpm@...ux-foundation.org, Denis Kirjanov <kda@...ux-powerpc.org>,
"Dominique Martinet" <dominique.martinet@....fr>,
"Hulk Robot" <hulkci@...wei.com>,
"zhengbin" <zhengbin13@...wei.com>
Subject: [PATCH 3.16 83/99] 9p/net: fix memory leak in p9_client_create
3.16.65-rc1 review patch. If anyone has any objections, please let me know.
------------------
From: zhengbin <zhengbin13@...wei.com>
commit bb06c388fa20ae24cfe80c52488de718a7e3a53f upstream.
If msize is less than 4096, we should close and put trans, destroy
tagpool, not just free client. This patch fixes that.
Link: http://lkml.kernel.org/m/1552464097-142659-1-git-send-email-zhengbin13@huawei.com
Fixes: 574d356b7a02 ("9p/net: put a lower bound on msize")
Reported-by: Hulk Robot <hulkci@...wei.com>
Signed-off-by: zhengbin <zhengbin13@...wei.com>
Signed-off-by: Dominique Martinet <dominique.martinet@....fr>
Signed-off-by: Ben Hutchings <ben@...adent.org.uk>
---
net/9p/client.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/net/9p/client.c
+++ b/net/9p/client.c
@@ -1066,7 +1066,7 @@ struct p9_client *p9_client_create(const
p9_debug(P9_DEBUG_ERROR,
"Please specify a msize of at least 4k\n");
err = -EINVAL;
- goto free_client;
+ goto close_trans;
}
err = p9_client_version(clnt);
Powered by blists - more mailing lists