summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorOlivier Blin <oblin@mandriva.org>2005-06-06 03:22:11 +0000
committerOlivier Blin <oblin@mandriva.org>2005-06-06 03:22:11 +0000
commitf31fed54311355559f8b9234863daa78edce465e (patch)
treed1a2dd96b6e1991d4f7b6dcfc81cb7cea776d9b8
parentabf477b292a33dd026a5f570544cac323dc6470d (diff)
downloaddrakx-f31fed54311355559f8b9234863daa78edce465e.tar
drakx-f31fed54311355559f8b9234863daa78edce465e.tar.gz
drakx-f31fed54311355559f8b9234863daa78edce465e.tar.bz2
drakx-f31fed54311355559f8b9234863daa78edce465e.tar.xz
drakx-f31fed54311355559f8b9234863daa78edce465e.zip
new netconnect API
-rw-r--r--perl-install/printer/printerdrake.pm6
-rwxr-xr-xperl-install/standalone/drakgw12
2 files changed, 6 insertions, 12 deletions
diff --git a/perl-install/printer/printerdrake.pm b/perl-install/printer/printerdrake.pm
index 2d3eba81b..076ec9314 100644
--- a/perl-install/printer/printerdrake.pm
+++ b/perl-install/printer/printerdrake.pm
@@ -4162,11 +4162,7 @@ sub check_network {
if ($::isInstall) {
my $o = $in;
require network::netconnect;
- network::netconnect::main(
- $o->{netcnx} ||= {},
- $in, $o->{modules_conf}, $o->{netc}, $o->{mouse},
- $o->{intf});
-# my ($prefix, $netcnx, $in, $o_netc, $o_mouse, $o_intf, $o_first_time, $o_noauto) = @_;
+ network::netconnect::real_main($o->{net}, $o, $o->{modules_conf});
} else {
system("/usr/sbin/drakconnect");
}
diff --git a/perl-install/standalone/drakgw b/perl-install/standalone/drakgw
index 18ca3e7aa..b7ad9dffa 100755
--- a/perl-install/standalone/drakgw
+++ b/perl-install/standalone/drakgw
@@ -52,10 +52,8 @@ unless ($kernel_version >= 2.4) {
$in->exit(-1);
}
-my $netc = {};
-my $netcnx = {};
-my $intfs = {};
-network::network::read_all_conf($::prefix, $netc, $intfs, $netcnx);
+my $net = {};
+network::network::read_net_conf($net);
my $modules_conf = modules::any_conf->read;
my %eth_intf = map { $_->[0] => join(': ', $_->[0], $_->[2]) } network::ethernet::get_eth_cards($modules_conf);
@@ -169,7 +167,7 @@ I am about to setup your Local Area Network with that adapter.", format_interfac
lan_configure =>
{
pre => sub {
- $lan_intf = $intfs->{$lan_interface_name} ||= {};
+ $lan_intf = $net->{ifcfg}{$lan_interface_name} ||= {};
$lan_intf->{DEVICE} = $lan_interface_name;
$lan_intf->{ONBOOT} = 'yes';
$lan_intf->{BOOTPROTO} = 'static';
@@ -187,14 +185,14 @@ I am about to setup your Local Area Network with that adapter.", format_interfac
},
complete => sub {
network::network::update_broadcast_and_network($lan_intf);
- if (my $conflict = find { $_->{NETWORK} eq $lan_intf->{NETWORK} } grep { $_->{DEVICE} ne $lan_intf->{DEVICE} } values %$intfs) {
+ if (my $conflict = find { $_->{NETWORK} eq $lan_intf->{NETWORK} } grep { $_->{DEVICE} ne $lan_intf->{DEVICE} } values %{$net->{ifcfg}}) {
$in->ask_warn(N("Error"), N("Potential LAN address conflict found in current config of %s!\n", $conflict->{DEVICE}));
return 1;
}
0;
},
post => sub {
- network::network::configureNetwork2($in, $modules_conf, $::prefix, $netc, $intfs) unless $::testing;
+ network::network::configure_network($net, $in, $modules_conf) unless $::testing;
return "dns";
},
},