mirror of
https://github.com/samba-team/samba.git
synced 2024-12-22 13:34:15 +03:00
traffic replay: allow --random-seed=0
Zero is a valid seed. Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
This commit is contained in:
parent
8760168aa8
commit
4c46333499
@ -71,7 +71,7 @@ def main():
|
|||||||
parser.add_option('-c', '--clean-up',
|
parser.add_option('-c', '--clean-up',
|
||||||
action="store_true",
|
action="store_true",
|
||||||
help='Clean up the generated groups and user accounts')
|
help='Clean up the generated groups and user accounts')
|
||||||
parser.add_option('--random-seed', type='int', default=0,
|
parser.add_option('--random-seed', type='int', default=None,
|
||||||
help='Use to keep randomness consistent across multiple runs')
|
help='Use to keep randomness consistent across multiple runs')
|
||||||
|
|
||||||
model_group = optparse.OptionGroup(parser, 'Traffic Model Options',
|
model_group = optparse.OptionGroup(parser, 'Traffic Model Options',
|
||||||
@ -173,7 +173,7 @@ def main():
|
|||||||
" for the users created as part of this test"))
|
" for the users created as part of this test"))
|
||||||
sys.exit(1)
|
sys.exit(1)
|
||||||
|
|
||||||
if opts.random_seed:
|
if opts.random_seed is not None:
|
||||||
random.seed(opts.random_seed)
|
random.seed(opts.random_seed)
|
||||||
|
|
||||||
creds = credopts.get_credentials(lp)
|
creds = credopts.get_credentials(lp)
|
||||||
|
Loading…
Reference in New Issue
Block a user