summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJeremy Katz <katzj@redhat.com>2007-10-10 18:30:08 +0000
committerJeremy Katz <katzj@redhat.com>2007-10-10 18:30:08 +0000
commitc9945be0b668e18308fc6b5890ff85aec11d868b (patch)
treef57da1715eb997c86e98fd4d13234510d1a36700
parent6b6b0fb456ca93b95e162ea7abeb752c219aa595 (diff)
downloadanaconda-c9945be0b668e18308fc6b5890ff85aec11d868b.tar.gz
anaconda-c9945be0b668e18308fc6b5890ff85aec11d868b.tar.xz
anaconda-c9945be0b668e18308fc6b5890ff85aec11d868b.zip
2007-10-10 Jeremy Katz <katzj@redhat.com>
* network.py (NetworkDevice.__str__): Don't traceback with unconfigured nics (#325071)
-rw-r--r--ChangeLog3
-rw-r--r--network.py3
2 files changed, 5 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index 6dd9cf5a9..73c5b49f5 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
2007-10-10 Jeremy Katz <katzj@redhat.com>
+ * network.py (NetworkDevice.__str__): Don't traceback with
+ unconfigured nics (#325071)
+
* upgrade.py (upgradeMountFilesystems): Check to see if we should
disable selinux based on whether the system has been booting with
selinux disabled (#242510)
diff --git a/network.py b/network.py
index 95604c9b0..4055788b6 100644
--- a/network.py
+++ b/network.py
@@ -132,7 +132,8 @@ class NetworkDevice(SimpleConfigFile):
# Don't let onboot be turned on unless we have config information
# to go along with it
- if self.get('bootproto').lower() != 'dhcp' and not self.get('ipaddr'):
+ proto = self.get('bootproto') or ""
+ if proto.lower() != 'dhcp' and not self.get('ipaddr'):
forceOffOnBoot = 1
else:
forceOffOnBoot = 0