summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThierry Vignaud <thierry.vignaud@gmail.com>2016-06-27 11:35:45 +0200
committerThierry Vignaud <thierry.vignaud@gmail.com>2016-06-27 11:35:45 +0200
commit7ff1b22c9a85a453773d6340b8e9cb8ee2c65de5 (patch)
treed085a68b62144d114ca7638d44c323e44846fce2
parentb39550da630baa8ce9d554f7b79a592c4dadc4f9 (diff)
downloaddrakx-net-7ff1b22c9a85a453773d6340b8e9cb8ee2c65de5.tar
drakx-net-7ff1b22c9a85a453773d6340b8e9cb8ee2c65de5.tar.gz
drakx-net-7ff1b22c9a85a453773d6340b8e9cb8ee2c65de5.tar.bz2
drakx-net-7ff1b22c9a85a453773d6340b8e9cb8ee2c65de5.tar.xz
drakx-net-7ff1b22c9a85a453773d6340b8e9cb8ee2c65de5.zip
fix crash when running with --skip-wizard
Resolves: mga#16772
-rw-r--r--NEWS3
-rw-r--r--lib/network/drakconnect/edit.pm6
2 files changed, 7 insertions, 2 deletions
diff --git a/NEWS b/NEWS
index 66909a2..157e786 100644
--- a/NEWS
+++ b/NEWS
@@ -1,3 +1,6 @@
+- drakconnect:
+ o fix crash when running with --skip-wizard (mga#16772)
+
2.24.1
- net_applet:
diff --git a/lib/network/drakconnect/edit.pm b/lib/network/drakconnect/edit.pm
index 965cc91..7918938 100644
--- a/lib/network/drakconnect/edit.pm
+++ b/lib/network/drakconnect/edit.pm
@@ -218,7 +218,9 @@ sub build_notebook {
foreach (qw(NEEDHOSTNAME PEERDNS)) { #- default these settings to yes
defined $intf->{$_} or $intf->{$_} = "yes";
}
- $gui->{intf}{$_}->set_text($intf->{$_}) foreach qw(DHCP_HOSTNAME DHCP_TIMEOUT);
+ foreach (qw(DHCP_HOSTNAME DHCP_TIMEOUT)) {
+ $intf->{$_} and $gui->{intf}{$_}->set_text($intf->{$_});
+ }
$gui->{intf_bool}{$_}->set_active(text2bool($intf->{$_})) foreach qw(NEEDHOSTNAME PEERDNS PEERYP PEERNTPD);
$gui->{intf}{DHCP_CLIENT}->set_text($intf->{DHCP_CLIENT});
$gui->{sheet}{DHCP}->set_sensitive($intf->{BOOTPROTO} eq 'dhcp');
@@ -291,7 +293,7 @@ sub build_notebook {
),
gtkpack__(Gtk3::HBox->new(0,1),
gtknew('Label_Left', text => N("Metric")),
- gtksignal_connect(gtkset_text($gui->{intf}{METRIC} = Gtk3::Entry->new, $intf->{METRIC}),
+ gtksignal_connect(gtkset_text($gui->{intf}{METRIC} = Gtk3::Entry->new, $intf->{METRIC} || ''),
key_press_event => $apply)),
);