[Patch] Remove needless checks in fs/9p/vfs_inode.c

From: Eric Sesterhenn
Date: Tue Jun 13 2006 - 16:06:00 EST


hi,

coverity found two needless checks in vfs_inode.c (cid #1165 and #1164)
In both cases inode is always NULL when we goto error; either because it
is still initialized to NULL or is set to NULL explicitly. This patch
simply removes these checks to save some code.

Signed-off-by: Eric Sesterhenn <snakebyte@xxxxxx>


--- linux-2.6.17-rc5/fs/9p/vfs_inode.c.orig 2006-06-13 22:01:56.000000000 +0200
+++ linux-2.6.17-rc5/fs/9p/vfs_inode.c 2006-06-13 22:02:18.000000000 +0200
@@ -530,9 +530,6 @@ error:
if (vfid)
v9fs_fid_destroy(vfid);

- if (inode)
- iput(inode);
-
return err;
}

@@ -1171,9 +1168,6 @@ error:
if (vfid)
v9fs_fid_destroy(vfid);

- if (inode)
- iput(inode);
-
return err;

}


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/