]> Pileus Git - ~andy/linux/commitdiff
[GFS2] gfs2_lookupi() uninitialised var fix
authorakpm@linux-foundation.org <akpm@linux-foundation.org>
Fri, 8 Jun 2007 23:42:14 +0000 (16:42 -0700)
committerSteven Whitehouse <swhiteho@redhat.com>
Mon, 9 Jul 2007 07:23:29 +0000 (08:23 +0100)
fs/gfs2/inode.c: In function 'gfs2_lookupi':
fs/gfs2/inode.c:392: warning: 'error' may be used uninitialized in this function

Looks like a real bug to me.

Cc: Steven Whitehouse <swhiteho@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
fs/gfs2/inode.c

index cacdb0dfe57789b139c444100c6f63036a72b3cb..366235d6a5b58a6fc8480cfcc3cce6767c64a11d 100644 (file)
@@ -389,7 +389,7 @@ struct inode *gfs2_lookupi(struct inode *dir, const struct qstr *name,
        struct super_block *sb = dir->i_sb;
        struct gfs2_inode *dip = GFS2_I(dir);
        struct gfs2_holder d_gh;
-       int error;
+       int error = 0;
        struct inode *inode = NULL;
        int unlock = 0;