s3-torture: run_oplock2(): replace cli_lock() with cli_lock32()
authorBjörn Baumbach <bb@sernet.de>
Mon, 18 Jul 2011 11:19:12 +0000 (13:19 +0200)
committerStefan Metzmacher <metze@samba.org>
Mon, 18 Jul 2011 21:27:54 +0000 (23:27 +0200)
Signed-off-by: Stefan Metzmacher <metze@samba.org>
source3/torture/torture.c

index 17b1379d1a7b05860f72f6c90b3dff6f7e7ce2dd..0158eb52ef53f563f3a76097a0ee660716c082f4 100644 (file)
@@ -3535,9 +3535,9 @@ static bool run_oplock2(int dummy)
 
        /* Should now be at level II. */
        /* Test if sending a write locks causes a break to none. */
-
-       if (!cli_lock(cli1, fnum1, 0, 4, 0, READ_LOCK)) {
-               printf("lock failed (%s)\n", cli_errstr(cli1));
+       status = cli_lock32(cli1, fnum1, 0, 4, 0, READ_LOCK);
+       if (!NT_STATUS_IS_OK(status)) {
+               printf("lock failed (%s)\n", nt_errstr(status));
                correct = False;
        }
 
@@ -3545,8 +3545,9 @@ static bool run_oplock2(int dummy)
 
        sleep(2);
 
-       if (!cli_lock(cli1, fnum1, 0, 4, 0, WRITE_LOCK)) {
-               printf("lock failed (%s)\n", cli_errstr(cli1));
+       status = cli_lock32(cli1, fnum1, 0, 4, 0, WRITE_LOCK);
+       if (!NT_STATUS_IS_OK(status)) {
+               printf("lock failed (%s)\n", nt_errstr(status));
                correct = False;
        }