lkml.org 
[lkml]   [2010]   [Aug]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [patch] ceph: ceph_get_inode() returns an ERR_PTR
Thanks, queueing this up!

sage


On Wed, 25 Aug 2010, Dan Carpenter wrote:

> ceph_get_inode() returns an ERR_PTR and it doesn't return a NULL.
>
> Signed-off-by: Dan Carpenter <error27@gmail.com>
>
> diff --git a/fs/ceph/inode.c b/fs/ceph/inode.c
> index 5d893d3..1e623ec 100644
> --- a/fs/ceph/inode.c
> +++ b/fs/ceph/inode.c
> @@ -1229,11 +1229,11 @@ retry_lookup:
> in = dn->d_inode;
> } else {
> in = ceph_get_inode(parent->d_sb, vino);
> - if (in == NULL) {
> + if (IS_ERR(in)) {
> dout("new_inode badness\n");
> d_delete(dn);
> dput(dn);
> - err = -ENOMEM;
> + err = PTR_ERR(in);
> goto out;
> }
> dn = splice_dentry(dn, in, NULL);
> --
> To unsubscribe from this list: send the line "unsubscribe ceph-devel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
>
>


\
 
 \ /
  Last update: 2010-08-25 21:03    [W:0.022 / U:0.016 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site