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

index e609ab08ec3756fa6d00a3e93fd7ae53fd8f65b1..9d2434b40a9a120b93f170a95ac82a83434f5bc8 100644 (file)
@@ -483,7 +483,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)