summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2019-08-15 11:09:47 +0200
committerStefan Metzmacher <metze@samba.org>2019-09-09 16:04:28 +0000
commit841fceae68098160627066dd6bd180948c048d96 (patch)
treecf5ada42a1ae37ee03a74159ded4dfe457a804b2
parentffdb166e49fa1a786ac1ea4e1ab09c286e75af69 (diff)
downloadsamba-841fceae68098160627066dd6bd180948c048d96.tar.gz
s3:blocking: demonstrate the posix lock retry fails
This is just a temporary commit that shows the bug and its fix. It will be reverted once the problem is fixed. The posix lock retry fails if the client specified timeout is smaller than the hardcoded 1 second retry. BUG: https://bugzilla.samba.org/show_bug.cgi?id=14113 Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Volker Lendecke <vl@samba.org> (cherry picked from commit 2ec9e93a7aac2706b4a5931495d56a7b64f8d894)
-rw-r--r--selftest/knownfail.d/lock91
-rw-r--r--source3/smbd/blocking.c4
2 files changed, 3 insertions, 2 deletions
diff --git a/selftest/knownfail.d/lock9 b/selftest/knownfail.d/lock9
new file mode 100644
index 00000000000..044622586eb
--- /dev/null
+++ b/selftest/knownfail.d/lock9
@@ -0,0 +1 @@
+^samba3.smbtorture_s3.*.LOCK9B
diff --git a/source3/smbd/blocking.c b/source3/smbd/blocking.c
index cdc4613270e..91438fe4486 100644
--- a/source3/smbd/blocking.c
+++ b/source3/smbd/blocking.c
@@ -236,7 +236,7 @@ struct tevent_req *smbd_smb1_do_locks_send(
DBG_DEBUG("Blocked on a posix lock. Retry in one second\n");
- tmp = timeval_current_ofs(1, 0);
+ tmp = timeval_current_ofs(15, 0);
endtime = timeval_min(&endtime, &tmp);
}
@@ -381,7 +381,7 @@ static void smbd_smb1_do_locks_retry(struct tevent_req *subreq)
DBG_DEBUG("Blocked on a posix lock. Retry in one second\n");
- tmp = timeval_current_ofs(1, 0);
+ tmp = timeval_current_ofs(15, 0);
endtime = timeval_min(&endtime, &tmp);
}