diff options
author | Jelmer Vernooij <jelmer@samba.org> | 2008-07-27 19:57:27 +0200 |
---|---|---|
committer | Jelmer Vernooij <jelmer@samba.org> | 2008-07-27 19:57:27 +0200 |
commit | 72d2bea916c19405f4fa996b7f781d73e3ee87c8 (patch) | |
tree | 3814912a6d73a09163152e56a0bc05288302dea2 /source4/torture/smbtorture.c | |
parent | 8d8ccc57e986d758a285a6af256ab945ccdac4dc (diff) | |
parent | 55ea54ec640e4a76df397becc211a81aaec6f09d (diff) | |
download | samba-72d2bea916c19405f4fa996b7f781d73e3ee87c8.tar.gz samba-72d2bea916c19405f4fa996b7f781d73e3ee87c8.tar.bz2 samba-72d2bea916c19405f4fa996b7f781d73e3ee87c8.zip |
Merge branch 'v4-0-test' of ssh://git.samba.org/data/git/samba into manpage
(This used to be commit 7e90cc197c4fb2884f368cd72f391d0d8016fb96)
Diffstat (limited to 'source4/torture/smbtorture.c')
-rw-r--r-- | source4/torture/smbtorture.c | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/source4/torture/smbtorture.c b/source4/torture/smbtorture.c index 37d7d171ca..1329f03b04 100644 --- a/source4/torture/smbtorture.c +++ b/source4/torture/smbtorture.c @@ -540,8 +540,9 @@ int main(int argc,char *argv[]) const char *basedir = NULL; const char *extra_module = NULL; static int list_tests = 0; + int num_extra_users = 0; enum {OPT_LOADFILE=1000,OPT_UNCLIST,OPT_TIMELIMIT,OPT_DNS, OPT_LIST, - OPT_DANGEROUS,OPT_SMB_PORTS,OPT_ASYNC,OPT_NUMPROGS}; + OPT_DANGEROUS,OPT_SMB_PORTS,OPT_ASYNC,OPT_NUMPROGS,OPT_EXTRA_USER}; struct poptOption long_options[] = { POPT_AUTOHELP @@ -569,6 +570,8 @@ int main(int argc,char *argv[]) "number of simultaneous async requests", NULL}, {"maximum-runtime", 0, POPT_ARG_INT, &max_runtime, 0, "set maximum time for smbtorture to live", "seconds"}, + {"extra-user", 0, POPT_ARG_STRING, NULL, OPT_EXTRA_USER, + "extra user credentials", NULL}, POPT_COMMON_SAMBA POPT_COMMON_CONNECTION POPT_COMMON_CREDENTIALS @@ -612,6 +615,15 @@ int main(int argc,char *argv[]) case OPT_SMB_PORTS: lp_set_cmdline(cmdline_lp_ctx, "smb ports", poptGetOptArg(pc)); break; + case OPT_EXTRA_USER: + { + char *option = talloc_asprintf(NULL, "torture:extra_user%u", + ++num_extra_users); + char *value = poptGetOptArg(pc); + lp_set_cmdline(cmdline_lp_ctx, option, value); + talloc_free(option); + } + break; } } |