From 473d7bad963bc5c9f5483e3432a96b5bf7ef73a7 Mon Sep 17 00:00:00 2001 From: David Cantrell Date: Tue, 4 Nov 2008 12:54:03 -1000 Subject: Prevent traceback when there are no network devices (#469339) If a user boots from boot.iso, the installer will bring up the net config dialog to configure the network interface so packages can be found and installed. If a user has no available network devices, the window appears but nothing is in the combo box. If they click the combo box, you get a traceback. This patch returns False from all enableNetwork() functions so the user sees the 'No Network Available' dialog and is given the Exit Installer button. --- text.py | 2 ++ 1 file changed, 2 insertions(+) (limited to 'text.py') diff --git a/text.py b/text.py index 7b5796225..d3dd568f8 100644 --- a/text.py +++ b/text.py @@ -496,6 +496,8 @@ class InstallInterface: return (passphrase, isglobal) def enableNetwork(self, anaconda): + if len(anaconda.id.network.netdevices) == 0: + return False from netconfig_text import NetworkConfiguratorText w = NetworkConfiguratorText(self.screen, anaconda) ret = w.run() -- cgit