LKML Archive on
help / color / mirror / Atom feed
From: Harvey Harrison <>
To: "Sergey S. Kostyliov" <>,
	Andrew Morton <>
Cc: LKML <>
Subject: [PATCH] befs: fix sparse warning in linuxvfs.c
Date: Fri, 15 Feb 2008 10:46:04 -0800	[thread overview]
Message-ID: <1203101164.15275.21.camel@brick> (raw)

Use link as the variable name to avoid shadowing the arg.

fs/befs/linuxvfs.c:492:8: warning: symbol 'p' shadows an earlier one
fs/befs/linuxvfs.c:488:77: originally declared here

Signed-off-by: Harvey Harrison <>
This should be checked in case there is a latent bug here.  Should it
be the arg *p getting freed, or the local var *p that was shadowing

 fs/befs/linuxvfs.c |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/fs/befs/linuxvfs.c b/fs/befs/linuxvfs.c
index 82123ff..e8717de 100644
--- a/fs/befs/linuxvfs.c
+++ b/fs/befs/linuxvfs.c
@@ -489,9 +489,9 @@ static void befs_put_link(struct dentry *dentry, struct nameidata *nd, void *p)
 	befs_inode_info *befs_ino = BEFS_I(dentry->d_inode);
 	if (befs_ino->i_flags & BEFS_LONG_SYMLINK) {
-		char *p = nd_get_link(nd);
-		if (!IS_ERR(p))
-			kfree(p);
+		char *link = nd_get_link(nd);
+		if (!IS_ERR(link))
+			kfree(link);

             reply	other threads:[~2008-02-15 18:46 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-02-15 18:46 Harvey Harrison [this message]
2008-02-15 21:19 ` Andrew Morton
2008-02-15 21:23   ` Harvey Harrison

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:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1203101164.15275.21.camel@brick \ \ \ \ \
    --subject='Re: [PATCH] befs: fix sparse warning in linuxvfs.c' \

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).