diff options
author | Olivier Blin <oblin@mandriva.org> | 2004-08-18 14:59:42 +0000 |
---|---|---|
committer | Olivier Blin <oblin@mandriva.org> | 2004-08-18 14:59:42 +0000 |
commit | b5d3fe2c8f45491a5c88515d0db0f59dc00091fe (patch) | |
tree | 628be5ce0e3e643c16172ca756e3fbeda9870863 /perl-install/network/network.pm | |
parent | 77e94ad51cfcdeaf6bc7bbd2f6cba171818b8a46 (diff) | |
download | drakx-backup-do-not-use-b5d3fe2c8f45491a5c88515d0db0f59dc00091fe.tar drakx-backup-do-not-use-b5d3fe2c8f45491a5c88515d0db0f59dc00091fe.tar.gz drakx-backup-do-not-use-b5d3fe2c8f45491a5c88515d0db0f59dc00091fe.tar.bz2 drakx-backup-do-not-use-b5d3fe2c8f45491a5c88515d0db0f59dc00091fe.tar.xz drakx-backup-do-not-use-b5d3fe2c8f45491a5c88515d0db0f59dc00091fe.zip |
(write_interface_conf) use mac_ieee1394 descriptor in iftab for firewire links
Diffstat (limited to 'perl-install/network/network.pm')
-rw-r--r-- | perl-install/network/network.pm | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/perl-install/network/network.pm b/perl-install/network/network.pm index 4b5049739..26e55beca 100644 --- a/perl-install/network/network.pm +++ b/perl-install/network/network.pm @@ -145,8 +145,10 @@ sub write_interface_conf { $intf->{HWADDR} &&= $mac_address; #- set HWADDR to MAC address if required #- write interface MAC address in iftab (if any) - my $descriptor = $link_type eq 'ether' ? 'mac' : 'unspec'; - substInFile { s/^$intf->{DEVICE}\s+.*\n//; $_ .= qq($intf->{DEVICE}\t$descriptor $mac_address\n) if eof } "$::prefix/etc/iftab" if $mac_address; + my $descriptor = ${{ ether => 'mac', ieee1394 => 'mac_ieee1394' }}{$link_type}; + if ($mac_address && $descriptor) { + substInFile { s/^$intf->{DEVICE}\s+.*\n//; $_ .= qq($intf->{DEVICE}\t$descriptor $mac_address\n) if eof } "$::prefix/etc/iftab"; + } my @ip = split '\.', $intf->{IPADDR}; my @mask = split '\.', $intf->{NETMASK}; |