From cdb8c99fce9b24d18f664f9ed42062f8a945e395 Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Thu, 13 Jan 2000 12:11:30 +0000 Subject: greatly expanded the lock4 locking test. we now pass all but one test - that should be fixed soon. (This used to be commit 23bb936e1fdeab2ad697ed946c945ef5ce87357d) --- source3/utils/torture.c | 138 ++++++++++++++++++++++++++++++++---------------- 1 file changed, 93 insertions(+), 45 deletions(-) (limited to 'source3/utils') diff --git a/source3/utils/torture.c b/source3/utils/torture.c index b9f0d76581..e905216d38 100644 --- a/source3/utils/torture.c +++ b/source3/utils/torture.c @@ -242,7 +242,7 @@ static BOOL rw_torture(struct cli_state *c) printf("unlink failed (%s)\n", cli_errstr(c)); } - if (!cli_unlock(c, fnum2, n*sizeof(int), sizeof(int), -1, F_WRLCK)) { + if (!cli_unlock(c, fnum2, n*sizeof(int), sizeof(int), -1)) { printf("unlock failed (%s)\n", cli_errstr(c)); } } @@ -563,7 +563,7 @@ static void run_locktest2(int dummy) cli_setpid(&cli, 2); - if (cli_unlock(&cli, fnum1, 0, 4, 0, F_WRLCK)) { + if (cli_unlock(&cli, fnum1, 0, 4, 0)) { printf("unlock1 succeeded! This is a locking bug\n"); } @@ -675,14 +675,14 @@ static void run_locktest3(int dummy) for (offset=i=0;i