host: skip lines beginning with new line

reviewable/pr18780/r1
Rene Moser 11 years ago
parent 502d9f43e5
commit ee9dc73a63

@ -100,7 +100,7 @@ class Host(object):
f.close() f.close()
for lineno, line in enumerate(self._hostsfile_lines): for lineno, line in enumerate(self._hostsfile_lines):
if line.startswith("#"): if line.startswith("#") or line.startswith("\n"):
continue continue
ip = line.split()[0:1] ip = line.split()[0:1]

Loading…
Cancel
Save