1
0
mirror of https://github.com/samba-team/samba.git synced 2025-02-05 21:57:51 +03:00

make the LOCK1 test randomise the time for the blocking lock test

(This used to be commit 28d325227c9b7ab48a47df006204319b21f7e7f7)
This commit is contained in:
Andrew Tridgell 2002-08-18 15:46:41 +00:00
parent d86b5fff06
commit a897c3ceda

View File

@ -829,7 +829,7 @@ static BOOL run_locktest1(int dummy)
printf("Testing lock timeouts\n");
t1 = time(NULL);
if (cli_lock(&cli2, fnum3, 0, 4, 10*1000, WRITE_LOCK)) {
if (cli_lock(&cli2, fnum3, 0, 4, (1 + (random() % 20)) * 1000, WRITE_LOCK)) {
printf("lock3 succeeded! This is a locking bug\n");
return False;
} else {