summaryrefslogtreecommitdiff
path: root/source3/torture
diff options
context:
space:
mode:
authorAndreas Schneider <asn@samba.org>2019-03-21 11:55:01 +0100
committerJeremy Allison <jra@samba.org>2019-03-21 20:38:32 +0000
commit9b1d79a5dd5e7caf967cf49936d2eb52175e85cf (patch)
tree41c744503fab38d7239b76a08acb55c10c2a18b6 /source3/torture
parent16331870eed8281cb85d9ea09858f14ae2b29329 (diff)
downloadsamba-9b1d79a5dd5e7caf967cf49936d2eb52175e85cf.tar.gz
s3:torture: Move the init of the locking out of the loop
Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
Diffstat (limited to 'source3/torture')
-rw-r--r--source3/torture/test_cleanup.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/source3/torture/test_cleanup.c b/source3/torture/test_cleanup.c
index 8efdf35e080..d3186db75d2 100644
--- a/source3/torture/test_cleanup.c
+++ b/source3/torture/test_cleanup.c
@@ -281,6 +281,11 @@ bool run_cleanup3(int dummy)
{ create_duplicate_batch, "create_duplicate_batch" },
};
+ if (!locking_init()) {
+ printf("locking_init failed\n");
+ return false;
+ }
+
printf("CLEANUP3: Checking that a share mode is cleaned up on "
"conflict\n");
@@ -296,10 +301,6 @@ bool run_cleanup3(int dummy)
printf("%d %d %d\n", (int)id.devid, (int)id.inode,
(int)id.extid);
- if (!locking_init()) {
- printf("locking_init failed\n");
- return false;
- }
lck = get_existing_share_mode_lock(talloc_tos(), id);
if (lck == NULL) {
printf("get_existing_share_mode_lock failed\n");