From 82e90789f11b5371b352a477b75cad0c5d1457ec Mon Sep 17 00:00:00 2001 From: Joshua Harlow Date: Mon, 12 Nov 2012 14:30:08 -0800 Subject: Cleanup of /etc/hosts ordering and pep8/pylint adjustments. Fix how the comparison of a fqdn and its aliases was done via sorting instead of existence checking which is the better way to check if a alias already exists as well as cleanup the new files pep8/pylint issues. LP: #1078097 --- cloudinit/distros/parsers/resolv_conf.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'cloudinit/distros/parsers/resolv_conf.py') diff --git a/cloudinit/distros/parsers/resolv_conf.py b/cloudinit/distros/parsers/resolv_conf.py index 377ada6b..5733c25a 100644 --- a/cloudinit/distros/parsers/resolv_conf.py +++ b/cloudinit/distros/parsers/resolv_conf.py @@ -127,7 +127,7 @@ class ResolvConf(object): # Hard restriction on only 6 search domains raise ValueError(("Adding %r would go beyond the " "'6' maximum search domains") % (search_domain)) - s_list = " ".join(new_sds) + s_list = " ".join(new_sds) if len(s_list) > 256: # Some hard limit on 256 chars total raise ValueError(("Adding %r would go beyond the " @@ -167,5 +167,3 @@ class ResolvConf(object): raise IOError("Unexpected resolv.conf option %s" % (cfg_opt)) entries.append(("option", [cfg_opt, cfg_values, tail])) return entries - - -- cgit v1.2.3