Ability to have comments in resolvers list (Closes #43)

This commit is contained in:
Babak Farrokhi 2018-01-23 12:25:46 +03:30
parent e3ddfff88e
commit 8283f4dbc2
Signed by: farrokhi
GPG Key ID: 6B267AD85D632E9A

View File

@ -266,7 +266,9 @@ def main():
if len(f) == 0:
print("No nameserver specified")
f = [name.strip() for name in f]
f = [name.strip() for name in f] # remove annoying blanks
f = [x for x in f if not x.startswith('#') and len(x)] # remove comments and empty entries
width = maxlen(f)
blanks = (width - 5) * ' '
print('server ', blanks, ' avg(ms) min(ms) max(ms) stddev(ms) lost(%) ttl flags')