summaryrefslogtreecommitdiff
path: root/source3/smbd/blocking.c
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2002-03-10 23:18:44 +0000
committerAndrew Tridgell <tridge@samba.org>2002-03-10 23:18:44 +0000
commit0843c37abd0a1520fc3117f91fc6284d9475c87e (patch)
tree1ec433f3f8470ff4f97654bfe4ada17ce92c4748 /source3/smbd/blocking.c
parente450ba6639accd00b112e1ce9089ef4b487d8b1c (diff)
downloadsamba-0843c37abd0a1520fc3117f91fc6284d9475c87e.tar.gz
samba-0843c37abd0a1520fc3117f91fc6284d9475c87e.tar.bz2
samba-0843c37abd0a1520fc3117f91fc6284d9475c87e.zip
failed timed locks always give LOCK_CONFLICT not LOCK_NOT_GRANTED
(This used to be commit ec71c1a66f9fd4b9cb4cad5a9b5b17e20de7aeb1)
Diffstat (limited to 'source3/smbd/blocking.c')
-rw-r--r--source3/smbd/blocking.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/source3/smbd/blocking.c b/source3/smbd/blocking.c
index 024e5b9f66..bc8c54caf7 100644
--- a/source3/smbd/blocking.c
+++ b/source3/smbd/blocking.c
@@ -175,6 +175,12 @@ static void generic_blocking_lock_error(blocking_lock_record *blr, NTSTATUS stat
char *inbuf = blr->inbuf;
construct_reply_common(inbuf, outbuf);
+ /* whenever a timeout is given w2k maps LOCK_NOT_GRANTED to
+ FILE_LOCK_CONFLICT! (tridge) */
+ if (NT_STATUS_EQUAL(status, NT_STATUS_LOCK_NOT_GRANTED)) {
+ status = NT_STATUS_FILE_LOCK_CONFLICT;
+ }
+
ERROR_NT(status);
if (!send_smb(smbd_server_fd(),outbuf))
exit_server("generic_blocking_lock_error: send_smb failed.");