diff options
author | Stefan Metzmacher <metze@samba.org> | 2006-10-17 12:06:20 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 14:21:18 -0500 |
commit | 87e8218d09088fbc13901ead300f7a5d1712f9a3 (patch) | |
tree | 1979042024d25d354c16c55cc0f67d51823df1bd | |
parent | 38d4fe0d53818110463fbf56e59ab597fde4e624 (diff) | |
download | samba-87e8218d09088fbc13901ead300f7a5d1712f9a3.tar.gz samba-87e8218d09088fbc13901ead300f7a5d1712f9a3.tar.bz2 samba-87e8218d09088fbc13901ead300f7a5d1712f9a3.zip |
r19369: - we need to set the target:samba3 before calling torture_init()
otherwise BASE-DELETE will run all tests
- call ldb_global_init() directly after torture_init()
this isn't strictly needed but looks better
metze
(This used to be commit 0c26c2aefdb603c5ffc87e9c0db0e9b2b34ec0ab)
-rw-r--r-- | source4/torture/smbtorture.c | 17 |
1 files changed, 7 insertions, 10 deletions
diff --git a/source4/torture/smbtorture.c b/source4/torture/smbtorture.c index 3733d72492..d83d1310ae 100644 --- a/source4/torture/smbtorture.c +++ b/source4/torture/smbtorture.c @@ -518,6 +518,12 @@ const static struct torture_ui_ops quiet_ui_ops = { } } + if (strcmp(target, "samba3") == 0) { + lp_set_cmdline("target:samba3", "true"); + } else if (strcmp(target, "samba4") == 0) { + lp_set_cmdline("target:samba4", "true"); + } + if (max_runtime) { /* this will only work if nobody else uses alarm(), which means it won't work for some tests, but we @@ -529,6 +535,7 @@ const static struct torture_ui_ops quiet_ui_ops = { } torture_init(); + ldb_global_init(); subunit_dir = lp_parm_string_list(-1, "torture", "subunitdir", ":"); if (subunit_dir == NULL) @@ -538,10 +545,6 @@ const static struct torture_ui_ops quiet_ui_ops = { torture_subunit_load_testsuites(subunit_dir[i], true, NULL); } - - - ldb_global_init(); - if (torture_seed == 0) { torture_seed = time(NULL); } @@ -563,12 +566,6 @@ const static struct torture_ui_ops quiet_ui_ops = { exit(1); } - if (strcmp(target, "samba3") == 0) { - lp_set_cmdline("target:samba3", "true"); - } else if (strcmp(target, "samba4") == 0) { - lp_set_cmdline("target:samba4", "true"); - } - /* see if its a RPC transport specifier */ if (is_binding_string(argv_new[1])) { lp_set_cmdline("torture:binding", argv_new[1]); |