diff options
author | carlosg <carlosg> | 2007-01-09 18:59:39 +0000 |
---|---|---|
committer | carlosg <carlosg> | 2007-01-09 18:59:39 +0000 |
commit | 56178318b31be1dbb308c91753e4477b200fb3c2 (patch) | |
tree | c9f8eadbe3627128041770b040027add7efee529 | |
parent | 7942eab4c1992e72a950bc9d40f20f86150db700 (diff) |
2007-01-09 Carlos Garnacho <carlosg@gnome.org>
* Network/Ifaces.pm (get_debian_bootproto) (set_debian_bootproto):
misc fixes to make extensible config methods work ok.
(interface_configured): parse correctly bootproto to determine whether
an interface is configured.
-rw-r--r-- | ChangeLog | 7 | ||||
-rw-r--r-- | Network/Ifaces.pm | 11 |
2 files changed, 13 insertions, 5 deletions
@@ -1,3 +1,10 @@ +2007-01-09 Carlos Garnacho <carlosg@gnome.org> + + * Network/Ifaces.pm (get_debian_bootproto) (set_debian_bootproto): + misc fixes to make extensible config methods work ok. + (interface_configured): parse correctly bootproto to determine whether + an interface is configured. + 2007-01-08 Carlos Garnacho <carlosg@gnome.org> * Network/Ifaces.pm (get_available_configuration_methods): oops, diff --git a/Network/Ifaces.pm b/Network/Ifaces.pm index bc26a8e..e87dc4d 100644 --- a/Network/Ifaces.pm +++ b/Network/Ifaces.pm @@ -361,7 +361,8 @@ sub get_debian_bootproto "dhcp" => "dhcp", "loopback" => "none", "ppp" => "none", - "static" => "static" + "static" => "static", + "ipv4ll" => "ipv4ll", ); &Utils::Report::enter (); @@ -400,7 +401,8 @@ sub set_debian_bootproto "dhcp" => "dhcp", "loopback" => "loopback", "ppp" => "ppp", - "none" => "static" + "none" => "static", + "ipv4ll" => "ipv4ll", ); my %dev_to_method = @@ -3512,11 +3514,11 @@ sub interface_configured if ($type eq "ethernet" || $type eq "irlan") { - return 1 if ($$iface{"bootproto"} eq "dhcp" || ($$iface{"address"} && $$iface{"netmask"})); + return 1 if (($$iface{"bootproto"} eq "static" && $$iface{"address"} && $$iface{"netmask"}) || $$iface{"bootproto"}); } elsif ($type eq "wireless") { - return 1 if (($$iface{"bootproto"} eq "dhcp" || ($$iface{"address"} && $$iface{"netmask"})) && $$iface{"essid"}); + return 1 if ((($$iface{"bootproto"} eq "static" && $$iface{"address"} && $$iface{"netmask"}) || $$iface{"bootproto"}) && $$iface{"essid"}); } elsif ($type eq "plip") { @@ -3599,7 +3601,6 @@ sub set_interfaces_config # only state has changed &$set_proc ($$values_hash{$i}, $$old_hash{$i}, $do_active, 1); } - } &Utils::Report::leave (); |