From: Ingo Molnar <mingo@elte.hu>
To: Trond Myklebust <trond.myklebust@fys.uio.no>
Cc: Yinghai Lu <yhlu.kernel@gmail.com>,
Pekka Enberg <penberg@cs.helsinki.fi>,
Arjan van de Ven <arjan@infradead.org>,
David Miller <davem@davemloft.net>,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: [PATCH] nfs: Fix nfs_parse_mount_options() kfree() leak
Date: Mon, 19 Oct 2009 10:39:34 +0200 [thread overview]
Message-ID: <20091019083934.GA28434@elte.hu> (raw)
In-Reply-To: <1255940951.14447.9.camel@heimdal.trondhjem.org>
* Trond Myklebust <trond.myklebust@fys.uio.no> wrote:
> > So d508afb fixed all that needed fixing and there's nothing serious
> > pending here. I've reverted all pending bits in tip:out-of-tree, so
> > it's pure -git now. I rarely have to carry any NFS fixes in
> > out-of-tree, this was an odd-one-out exception that fell through the
> > cracks.
> >
> > Ingo
>
> OK. Could you resend the remaining leak fix, with the fixed up
> changelog and attributions so I can pass it on to Linus?
Sure - find it below.
Thanks,
Ingo
-------------------------------------------->
>From 42497c08be18c388f696a692ca5f8c3ba48cb183 Mon Sep 17 00:00:00 2001
From: Yinghai Lu <yinghai@kernel.org>
Date: Fri, 3 Apr 2009 09:06:15 +0200
Subject: [PATCH] nfs: Fix nfs_parse_mount_options() kfree() leak
Fix a (small) memory leak in one of the error paths of
the NFS mount options parsing code.
Reported-by: Yinghai Lu <yinghai@kernel.org>
Reported-by: Pekka Enberg <penberg@cs.helsinki.fi>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
---
fs/nfs/super.c | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/fs/nfs/super.c b/fs/nfs/super.c
index a2c18ac..90be551 100644
--- a/fs/nfs/super.c
+++ b/fs/nfs/super.c
@@ -1253,6 +1253,7 @@ static int nfs_parse_mount_options(char *raw,
default:
dfprintk(MOUNT, "NFS: unrecognized "
"transport protocol\n");
+ kfree(string);
return 0;
}
break;
next prev parent reply other threads:[~2009-10-19 8:39 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-10-18 1:25 nfs mount fail Yinghai Lu
2009-10-18 4:22 ` Yinghai Lu
2009-10-19 2:35 ` Pekka Enberg
2009-10-19 2:43 ` Arjan van de Ven
2009-10-19 2:58 ` Pekka Enberg
2009-10-19 5:52 ` Yinghai Lu
2009-10-19 6:30 ` Trond Myklebust
2009-10-19 6:54 ` Ingo Molnar
2009-10-19 6:58 ` Pekka Enberg
2009-10-19 7:08 ` Ingo Molnar
2009-10-19 7:31 ` Yinghai Lu
2009-10-19 7:52 ` Trond Myklebust
2009-10-19 8:04 ` Ingo Molnar
2009-10-19 8:23 ` Ingo Molnar
2009-10-19 8:29 ` Trond Myklebust
2009-10-19 8:39 ` Ingo Molnar [this message]
2009-10-19 7:04 ` [re-send PATCH] nfs: Fix nfs_parse_mount_options() double kfree() Ingo Molnar
2009-10-19 7:10 ` Ingo Molnar
2009-10-19 7:04 ` nfs mount fail Trond Myklebust
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20091019083934.GA28434@elte.hu \
--to=mingo@elte.hu \
--cc=arjan@infradead.org \
--cc=davem@davemloft.net \
--cc=linux-kernel@vger.kernel.org \
--cc=penberg@cs.helsinki.fi \
--cc=trond.myklebust@fys.uio.no \
--cc=yhlu.kernel@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®