]> err.no Git - linux-2.6/commitdiff
NFS: Fix a bug in nfs_open_revalidate()
authorTrond Myklebust <Trond.Myklebust@netapp.com>
Wed, 3 Oct 2007 19:58:38 +0000 (15:58 -0400)
committerTrond Myklebust <Trond.Myklebust@netapp.com>
Tue, 9 Oct 2007 21:19:30 +0000 (17:19 -0400)
We want to set the verifier when the call to nfs4_open_revalidate()
_succeeds_.

Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
fs/nfs/dir.c

index 166a833be6611910d69ac5b4add99bb9f76a69fe..d58bfb81354e50ef2e84ddae4d8cea95d07c716e 100644 (file)
@@ -1078,7 +1078,7 @@ static int nfs_open_revalidate(struct dentry *dentry, struct nameidata *nd)
        lock_kernel();
        verifier = nfs_save_change_attribute(dir);
        ret = nfs4_open_revalidate(dir, dentry, openflags, nd);
-       if (!ret)
+       if (ret == 1)
                nfs_set_verifier(dentry, verifier);
        unlock_kernel();
 out: