diff options
author | Thierry Vignaud <tvignaud@mandriva.org> | 2004-01-28 18:10:08 +0000 |
---|---|---|
committer | Thierry Vignaud <tvignaud@mandriva.org> | 2004-01-28 18:10:08 +0000 |
commit | a1eebb625ff30b1bcb0a558bca8a61433c2fdb22 (patch) | |
tree | 3d8fc7e3149f58cfb12c415b0d593fc63b7eeba2 /perl-install/network | |
parent | 8fe09f91409f415dc3efbe26f029dc6edf75db81 (diff) | |
download | drakx-a1eebb625ff30b1bcb0a558bca8a61433c2fdb22.tar drakx-a1eebb625ff30b1bcb0a558bca8a61433c2fdb22.tar.gz drakx-a1eebb625ff30b1bcb0a558bca8a61433c2fdb22.tar.bz2 drakx-a1eebb625ff30b1bcb0a558bca8a61433c2fdb22.tar.xz drakx-a1eebb625ff30b1bcb0a558bca8a61433c2fdb22.zip |
(adsl_probe_info) minor cleanups
Diffstat (limited to 'perl-install/network')
-rw-r--r-- | perl-install/network/adsl.pm | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/perl-install/network/adsl.pm b/perl-install/network/adsl.pm index 6ec018efd..be1d7e143 100644 --- a/perl-install/network/adsl.pm +++ b/perl-install/network/adsl.pm @@ -69,15 +69,15 @@ sub adsl_probe_info { my ($adsl, $netc, $adsl_type, $adsl_modem) = @_; my $pppoe_file = "$::prefix/etc/ppp/pppoe.conf"; my $pptp_file = "$::prefix/etc/sysconfig/network-scripts/net_cnx_up"; - my %pppoe_conf; %pppoe_conf = getVarsFromSh($pppoe_file) if (! defined $adsl_type || $adsl_type =~ /pppoe/) && -f $pppoe_file; + my %pppoe_conf; %pppoe_conf = getVarsFromSh($pppoe_file) if (! defined $adsl_type || $adsl_type eq 'pppoe') && -f $pppoe_file; my $login = $pppoe_conf{USER}; foreach (qw(/etc/ppp/peers/adsl /etc/ppp/options /etc/ppp/options.adsl)) { ($login) = map { if_(/^user\s+"([^"]+)"/, $1) } cat_("$::prefix/$_") if !$login && -r "$::prefix/$_"; } - ($login) = map { if_(/\sname\s+([^ \n]+)/, $1) } cat_($pptp_file) if (! defined $adsl_type || $adsl_type =~ /pptp/) && -r $pptp_file; + ($login) = map { if_(/\sname\s+([^ \n]+)/, $1) } cat_($pptp_file) if (! defined $adsl_type || $adsl_type eq 'pptp') && -r $pptp_file; my $passwd = passwd_by_login($login); ($netc->{vpi}, $netc->{vci}) = - map { if_(/^.*-vpi\s+(\d+)\s+-vci\s+(\d+)/, $1, $2) } cat_("$::prefix/etc/ppp/peers/adsl") if $adsl_modem =~ /eci|speedtouch/; + map { if_(/^.*-vpi\s+(\d+)\s+-vci\s+(\d+)/, $1, $2) } cat_("$::prefix/etc/ppp/peers/adsl") if member($adsl_modem, qw(eci speedtouch)); $pppoe_conf{DNS1} ||= ''; $pppoe_conf{DNS2} ||= ''; add2hash($netc, { dnsServer2 => $pppoe_conf{DNS1}, dnsServer3 => $pppoe_conf{DNS2}, DOMAINNAME2 => '' }); |