From ea655984fc22b95793a7d09671fc699083dc4238 Mon Sep 17 00:00:00 2001 From: Thierry Vignaud Date: Tue, 19 Nov 2013 00:56:32 +0100 Subject: fix various "undefined value for mandatory argument..." --- bin/drakinvictus | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'bin') diff --git a/bin/drakinvictus b/bin/drakinvictus index eaf6fe1..1df1ced 100755 --- a/bin/drakinvictus +++ b/bin/drakinvictus @@ -47,18 +47,18 @@ my $invictus = {}; network::invictus::read_config($invictus); my %interface_addresses = map { $_ => { - real_address => gtknew('Entry', text => $invictus->{ucarp}{$_}{SRCIP}), - virtual_address => gtknew('Entry', text => $invictus->{ucarp}{$_}{VIRTIP}), - vid => do { my $w = gtknew('Entry', text => $invictus->{ucarp}{$_}{VHID}); $w->set_width_chars(5); $w }, + real_address => gtknew('Entry', text => $invictus->{ucarp}{$_}{SRCIP} || ''), + virtual_address => gtknew('Entry', text => $invictus->{ucarp}{$_}{VIRTIP} || ''), + vid => do { my $w = gtknew('Entry', text => $invictus->{ucarp}{$_}{VHID} || ''); $w->set_width_chars(5); $w }, } } @interfaces; my $master_checkbutton = gtknew('CheckButton', text => N("Start as master"), active => do { my $m = find { $_->{TAKEOVER} } values %{$invictus->{ucarp}}; - $m && text2bool($m->{TAKEOVER}); + $m ? text2bool($m->{TAKEOVER}) : 0; }); my $password_entry = gtknew('Entry', text => do { my $p = find { $_->{PASSWORD} } values %{$invictus->{ucarp}}; - $p && $p->{PASSWORD}; + $p ? $p->{PASSWORD} : ''; }); $password_entry->set_visibility(0); my $ct_sync_interface_list; -- cgit v1.2.1