From: "Jan Beulich" <jbeulich@novell.com>
To: <sam@ravnborg.org>
Cc: <linux-kernel@vger.kernel.org>
Subject: [PATCH] remove pointless strdup() on arguments passed to new_module()
Date: Thu, 12 Mar 2009 12:28:30 +0000 [thread overview]
Message-ID: <49B90DFE.76E4.0078.0@novell.com> (raw)
new_module() itself already calls strdup() on its modname parameter.
Signed-off-by: Jan Beulich <jbeulich@novell.com>
---
scripts/mod/modpost.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
--- linux-2.6.29-rc7/scripts/mod/modpost.c 2008-12-25 00:26:37.000000000 +0100
+++ 2.6.29-rc7-module-modpost/scripts/mod/modpost.c 2009-01-20 09:47:23.000000000 +0100
@@ -1910,7 +1910,7 @@ static void read_dump(const char *fname,
if (!mod) {
if (is_vmlinux(modname))
have_vmlinux = 1;
- mod = new_module(NOFAIL(strdup(modname)));
+ mod = new_module(modname);
mod->skip = 1;
}
s = sym_add_exported(symname, mod, export_no(export));
@@ -1994,7 +1994,7 @@ static void read_markers(const char *fna
mod = find_module(modname);
if (!mod) {
- mod = new_module(NOFAIL(strdup(modname)));
+ mod = new_module(modname);
mod->skip = 1;
}
if (is_vmlinux(modname)) {
next reply other threads:[~2009-03-12 12:28 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-03-12 12:28 Jan Beulich [this message]
2009-04-10 7:01 ` Sam Ravnborg
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=49B90DFE.76E4.0078.0@novell.com \
--to=jbeulich@novell.com \
--cc=linux-kernel@vger.kernel.org \
--cc=sam@ravnborg.org \
/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
Powered by JetHome