Commit f9c5a9dc authored by juga's avatar juga
Browse files

scanner: stop logging rtt when is not perform

If rtt is configured to 0, the rtt measurements are not run,
but it was being logged that they're run
parent 738dc181
......@@ -78,8 +78,8 @@ def measure_rtt_to_server(session, conf, dest, content_length):
be made, return None. Otherwise return a list of the RTTs (in seconds). '''
rtts = []
size = conf.getint('scanner', 'min_download_size')
log.debug('Measuring RTT to %s', dest.url)
for _ in range(0, conf.getint('scanner', 'num_rtts')):
log.debug('Measuring RTT to %s', dest.url)
random_range = get_random_range_string(content_length, size)
success, data = timed_recv_from_server(session, dest, random_range)
if not success:
......
Supports Markdown
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