summaryrefslogtreecommitdiffstats
path: root/perl-install
diff options
context:
space:
mode:
Diffstat (limited to 'perl-install')
-rw-r--r--perl-install/network/network.pm7
1 files changed, 5 insertions, 2 deletions
diff --git a/perl-install/network/network.pm b/perl-install/network/network.pm
index ae871084e..d0094fc4c 100644
--- a/perl-install/network/network.pm
+++ b/perl-install/network/network.pm
@@ -74,7 +74,7 @@ sub read_squid_conf {
sub read_tmdns_conf {
my ($file) = @_;
- local *F; open F, $file or die "cannot open file $file: $!";
+ local *F; open $F, $file or die "cannot open file $file: $!";
local $_;
my %outf;
@@ -168,7 +168,10 @@ sub write_interface_conf {
$intf->{BOOTPROTO} =~ s/dhcp.*/dhcp/;
- local $intf->{WIRELESS_ENC_KEY} = $intf->{WIRELESS_ENC_KEY} && network::tools::convert_wep_key_for_iwconfig($intf->{WIRELESS_ENC_KEY});
+ if (local $intf->{WIRELESS_ENC_KEY} = $intf->{WIRELESS_ENC_KEY}) {
+ network::tools::convert_wep_key_for_iwconfig($intf->{WIRELESS_ENC_KEY});
+ }
+
setVarsInSh($file, $intf, qw(DEVICE BOOTPROTO IPADDR NETMASK NETWORK BROADCAST ONBOOT HWADDR MII_NOT_SUPPORTED),
qw(WIRELESS_MODE WIRELESS_ESSID WIRELESS_NWID WIRELESS_FREQ WIRELESS_SENS WIRELESS_RATE WIRELESS_ENC_KEY WIRELESS_RTS WIRELESS_FRAG WIRELESS_IWCONFIG WIRELESS_IWSPY WIRELESS_IWPRIV),
if_($intf->{BOOTPROTO} eq "dhcp", qw(DHCP_HOSTNAME NEEDHOSTNAME))