diff options
Diffstat (limited to 'fs/nfsd/nfs4state.c')
| -rw-r--r-- | fs/nfsd/nfs4state.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c index af360705e551..e42c7a0eb6fa 100644 --- a/fs/nfsd/nfs4state.c +++ b/fs/nfsd/nfs4state.c | |||
| @@ -2813,7 +2813,6 @@ nfsd4_lockt(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate, | |||
| 2813 | struct inode *inode; | 2813 | struct inode *inode; |
| 2814 | struct file file; | 2814 | struct file file; |
| 2815 | struct file_lock file_lock; | 2815 | struct file_lock file_lock; |
| 2816 | struct file_lock conflock; | ||
| 2817 | __be32 status; | 2816 | __be32 status; |
| 2818 | 2817 | ||
| 2819 | if (nfs4_in_grace()) | 2818 | if (nfs4_in_grace()) |
| @@ -2878,9 +2877,10 @@ nfsd4_lockt(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate, | |||
| 2878 | file.f_path.dentry = cstate->current_fh.fh_dentry; | 2877 | file.f_path.dentry = cstate->current_fh.fh_dentry; |
| 2879 | 2878 | ||
| 2880 | status = nfs_ok; | 2879 | status = nfs_ok; |
| 2881 | if (posix_test_lock(&file, &file_lock, &conflock)) { | 2880 | posix_test_lock(&file, &file_lock); |
| 2881 | if (file_lock.fl_type != F_UNLCK) { | ||
| 2882 | status = nfserr_denied; | 2882 | status = nfserr_denied; |
| 2883 | nfs4_set_lock_denied(&conflock, &lockt->lt_denied); | 2883 | nfs4_set_lock_denied(&file_lock, &lockt->lt_denied); |
| 2884 | } | 2884 | } |
| 2885 | out: | 2885 | out: |
| 2886 | nfs4_unlock_state(); | 2886 | nfs4_unlock_state(); |
