summaryrefslogtreecommitdiff
path: root/source4/ntvfs/posix
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2009-11-26 17:38:50 +1100
committerAndrew Tridgell <tridge@samba.org>2009-11-27 16:05:06 +1100
commitd3d7ca8eeab13c00705188102855525a21dd5345 (patch)
tree80d1c40ddddab9b89d581ced76b4ed87c311f85c /source4/ntvfs/posix
parent7c158bdb1d0e217e06f54d2e2cef12a5433d3578 (diff)
downloadsamba-d3d7ca8eeab13c00705188102855525a21dd5345.tar.gz
s4-smb2: SMB2 uses NT_STATUS_CANCELLED for cancelled locks
Diffstat (limited to 'source4/ntvfs/posix')
-rw-r--r--source4/ntvfs/posix/pvfs_lock.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/source4/ntvfs/posix/pvfs_lock.c b/source4/ntvfs/posix/pvfs_lock.c
index 711c924ae3f..11757deea49 100644
--- a/source4/ntvfs/posix/pvfs_lock.c
+++ b/source4/ntvfs/posix/pvfs_lock.c
@@ -116,7 +116,11 @@ static void pvfs_pending_lock_continue(void *private_data, enum pvfs_wait_notice
/* we don't retry on a cancel */
if (reason == PVFS_WAIT_CANCEL) {
- status = NT_STATUS_FILE_LOCK_CONFLICT;
+ if (pvfs->ntvfs->ctx->protocol != PROTOCOL_SMB2) {
+ status = NT_STATUS_FILE_LOCK_CONFLICT;
+ } else {
+ status = NT_STATUS_CANCELLED;
+ }
} else {
/*
* here it's important to pass the pending pointer