Unionfs: initialize namelist variable in rename
authorErez Zadok <ezk@cs.sunysb.edu>
Tue, 25 Dec 2007 22:03:29 +0000 (17:03 -0500)
committerErez Zadok <ezk@cs.sunysb.edu>
Tue, 25 Dec 2007 22:03:29 +0000 (17:03 -0500)
Signed-off-by: Erez Zadok <ezk@cs.sunysb.edu>
fs/unionfs/rename.c

index 97b441987ddeb098e73cc8e2a2b8126918c9bfdc..bc71e8ef0242604f33f5e01953ce3be91fec53ec 100644 (file)
@@ -457,7 +457,7 @@ int unionfs_rename(struct inode *old_dir, struct dentry *old_dentry,
                }
 
                if (S_ISDIR(new_dentry->d_inode->i_mode)) {
-                       struct unionfs_dir_state *namelist;
+                       struct unionfs_dir_state *namelist = NULL;
                        /* check if this unionfs directory is empty or not */
                        err = check_empty(new_dentry, &namelist);
                        if (err)