Commit d20d5843 authored by Steve French's avatar Steve French Committed by Chris Wright

[PATCH] CIFS: New POSIX locking code not setting rc properly to zero on successful

unlock in case where server does not support POSIX locks and nobrl is
not specified.
Signed-off-by: default avatarSteve French <sfrench@us.ibm.com>
Signed-off-by: default avatarChris Wright <chrisw@sous-sol.org>
parent 1d520e58
......@@ -752,6 +752,7 @@ int cifs_lock(struct file *file, int cmd, struct file_lock *pfLock)
int stored_rc = 0;
struct cifsLockInfo *li, *tmp;
rc = 0;
down(&fid->lock_sem);
list_for_each_entry_safe(li, tmp, &fid->llist, llist) {
if (pfLock->fl_start <= li->offset &&
......@@ -766,7 +767,7 @@ int cifs_lock(struct file *file, int cmd, struct file_lock *pfLock)
kfree(li);
}
}
up(&fid->lock_sem);
up(&fid->lock_sem);
}
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment