Commit aabc9550 authored by Stephane Bortzmeyer's avatar Stephane Bortzmeyer
Browse files

Option handling: opts prefix forgotten

parent 1466ea72
......@@ -421,7 +421,7 @@ def parse_opts(opts):
error_and_exit("--repeat needs a value > 1")
elif option == "--delay" or option == "-d":
opts.delay = float(value)
if delay <= 0:
if opts.delay <= 0:
error_and_exit("--delay needs a value > 0")
elif option == "--file" or option == "-f":
opts.ifile = value
......@@ -435,9 +435,9 @@ def parse_opts(opts):
opts.pipelining = True
elif option == "--max-in-flight":
opts.max_in_flight = int(value)
if max_in_flight <= 0:
if opts.max_in_flight <= 0:
error_and_exit("--max_in_flight but be > 0")
if max_in_flight >= 65536:
if opts.max_in_flight >= 65536:
error_and_exit("Because of a limit of the DNS protocol (the size of the query ID) --max_in_flight must be < 65 536")
elif option == "--check":
opts.check = True
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment