]> git.baikalelectronics.ru Git - kernel.git/commitdiff
NFS: Fix a typo in nfs_rename()
authorTrond Myklebust <trond.myklebust@primarydata.com>
Mon, 6 Nov 2017 20:28:04 +0000 (15:28 -0500)
committerAnna Schumaker <Anna.Schumaker@Netapp.com>
Fri, 17 Nov 2017 21:43:46 +0000 (16:43 -0500)
On successful rename, the "old_dentry" is retained and is attached to
the "new_dir", so we need to call nfs_set_verifier() accordingly.

Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com>
Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
fs/nfs/dir.c

index a642ed3b13d900dd256bac219ea64210d506a47b..927fd2768eadeeb4ce57ab7438e802e640cac9ea 100644 (file)
@@ -2057,7 +2057,7 @@ out:
                 * should mark the directories for revalidation.
                 */
                d_move(old_dentry, new_dentry);
-               nfs_set_verifier(new_dentry,
+               nfs_set_verifier(old_dentry,
                                        nfs_save_change_attribute(new_dir));
        } else if (error == -ENOENT)
                nfs_dentry_handle_enoent(old_dentry);