From: Dave Kleikamp <shaggy@linux.vnet.ibm.com>
To: Marcin Slusarz <marcin.slusarz@gmail.com>
Cc: LKML <linux-kernel@vger.kernel.org>,
jfs-discussion@lists.sourceforge.net,
Alexander Viro <viro@zeniv.linux.org.uk>
Subject: Re: [PATCH] jfs: 0 is not valid errno value
Date: Mon, 12 May 2008 16:49:49 -0500 [thread overview]
Message-ID: <1210628989.13027.4.camel@norville.austin.ibm.com> (raw)
In-Reply-To: <20080511200842.GN19058@joi>
On Sun, 2008-05-11 at 22:08 +0200, Marcin Slusarz wrote:
> ... so return NULL from jfs_lookup
>
> Signed-off-by: Marcin Slusarz <marcin.slusarz@gmail.com>
Signed-off-by: Dave Kleikamp <shaggy@linux.vnet.ibm.com>
> Cc: jfs-discussion@lists.sourceforge.net
> Cc: Alexander Viro <viro@zeniv.linux.org.uk>
> ---
> is it ok to return NULL from this function?
> compile tested only
Yeah. I'm not sure how ERR_PTR(0) got in there in the first place.
It's been that way for quite a while.
I'll add it to the jfs git tree.
Thanks,
Shaggy
> ---
> fs/jfs/namei.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/fs/jfs/namei.c b/fs/jfs/namei.c
> --- a/fs/jfs/namei.c
> +++ b/fs/jfs/namei.c
> @@ -1455,7 +1455,7 @@ static struct dentry *jfs_lookup(struct inode *dip, struct dentry *dentry, struc
> free_UCSname(&key);
> if (rc == -ENOENT) {
> d_add(dentry, NULL);
> - return ERR_PTR(0);
> + return NULL;
> } else if (rc) {
> jfs_err("jfs_lookup: dtSearch returned %d", rc);
> return ERR_PTR(rc);
--
David Kleikamp
IBM Linux Technology Center
prev parent reply other threads:[~2008-05-12 21:50 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-05-11 20:08 Marcin Slusarz
2008-05-12 21:49 ` Dave Kleikamp [this message]
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=1210628989.13027.4.camel@norville.austin.ibm.com \
--to=shaggy@linux.vnet.ibm.com \
--cc=jfs-discussion@lists.sourceforge.net \
--cc=linux-kernel@vger.kernel.org \
--cc=marcin.slusarz@gmail.com \
--cc=viro@zeniv.linux.org.uk \
/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®