From 59206674521065e041a6020f9ba793fac47b1d7d Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Sat, 1 Nov 2008 00:24:55 +0100 Subject: Split out torture results from torture context. --- source4/torture/smbtorture.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'source4/torture/smbtorture.c') diff --git a/source4/torture/smbtorture.c b/source4/torture/smbtorture.c index 19f1d1ae35..bfe6d0503d 100644 --- a/source4/torture/smbtorture.c +++ b/source4/torture/smbtorture.c @@ -370,7 +370,7 @@ static void quiet_suite_start(struct torture_context *ctx, struct torture_suite *suite) { int i; - ctx->quiet = true; + ctx->results->quiet = true; for (i = 1; i < ctx->level; i++) putchar('\t'); printf("%s: ", suite->name); fflush(stdout); @@ -456,6 +456,7 @@ int main(int argc,char *argv[]) int max_runtime=0; int argc_new; struct torture_context *torture; + struct torture_results *results; const struct torture_ui_ops *ui_ops; char **argv_new; poptContext pc; @@ -627,7 +628,9 @@ int main(int argc,char *argv[]) exit(1); } - torture = torture_context_init(s4_event_context_init(NULL), ui_ops); + results = torture_results_init(talloc_autofree_context(), ui_ops); + + torture = torture_context_init(s4_event_context_init(NULL), results); if (basedir != NULL) { if (basedir[0] != '/') { fprintf(stderr, "Please specify an absolute path to --basedir\n"); @@ -657,7 +660,7 @@ int main(int argc,char *argv[]) } } - if (torture->returncode && correct) { + if (torture->results->returncode && correct) { return(0); } else { return(1); -- cgit From b45caa44e1a563a3af42e39bd61ee4a2b74db14f Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Sun, 2 Nov 2008 23:58:49 +0100 Subject: Fix the build. --- source4/torture/smbtorture.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'source4/torture/smbtorture.c') diff --git a/source4/torture/smbtorture.c b/source4/torture/smbtorture.c index bfe6d0503d..0c2c8c0f6b 100644 --- a/source4/torture/smbtorture.c +++ b/source4/torture/smbtorture.c @@ -33,6 +33,7 @@ #include "torture/smbtorture.h" #include "../lib/util/dlinklist.h" #include "librpc/rpc/dcerpc.h" +#include "auth/gensec/gensec.h" #include "param/param.h" #include "auth/credentials/credentials.h" @@ -648,6 +649,8 @@ int main(int argc,char *argv[]) torture->lp_ctx = cmdline_lp_ctx; + gensec_init(cmdline_lp_ctx); + if (argc_new == 0) { printf("You must specify a test to run, or 'ALL'\n"); } else if (shell) { -- cgit