summaryrefslogtreecommitdiffstats
path: root/perl-install/diskdrake/interactive.pm
diff options
context:
space:
mode:
authorThierry Vignaud <thierry.vignaud@gmail.com>2016-11-14 16:41:25 +0100
committerThierry Vignaud <thierry.vignaud@gmail.com>2016-11-15 08:34:45 +0100
commit84405a3bde840a526b4bea650fbe69963a900ef5 (patch)
tree6b3596470da38d4de6fe557e3de244f4f2f13b96 /perl-install/diskdrake/interactive.pm
parentb218bd62a701c25dd1b6f95a6e6c300b6529ba3e (diff)
downloaddrakx-84405a3bde840a526b4bea650fbe69963a900ef5.tar
drakx-84405a3bde840a526b4bea650fbe69963a900ef5.tar.gz
drakx-84405a3bde840a526b4bea650fbe69963a900ef5.tar.bz2
drakx-84405a3bde840a526b4bea650fbe69963a900ef5.tar.xz
drakx-84405a3bde840a526b4bea650fbe69963a900ef5.zip
warn when an action condition is bogus (mga#19172)
thus showing we were using an unexported function for format test
Diffstat (limited to 'perl-install/diskdrake/interactive.pm')
-rw-r--r--perl-install/diskdrake/interactive.pm6
1 files changed, 5 insertions, 1 deletions
diff --git a/perl-install/diskdrake/interactive.pm b/perl-install/diskdrake/interactive.pm
index f982301e3..5a6f853e4 100644
--- a/perl-install/diskdrake/interactive.pm
+++ b/perl-install/diskdrake/interactive.pm
@@ -442,7 +442,11 @@ sub part_possible_actions {
$cond =~ s/$k/qq(($v))/e;
}
$cond =~ s/(^|[^:\$]) \b ([a-z]\w{3,}) \b ($|[\s&\)])/$1 . $2 . '($part)' . $3/exg;
- eval $cond;
+ my $res = eval $cond;
+ if (my $err = $@) {
+ warn "ERROR: Bogus condition for '$actions{$_}': $err\n";
+ }
+ $res;
} @$actions_names;
}
}