summaryrefslogtreecommitdiffstats
path: root/perl-install
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2004-06-01 08:34:22 +0000
committerPascal Rigaux <pixel@mandriva.com>2004-06-01 08:34:22 +0000
commitd67d1856ab717c9a0b00487b815314084a4fa34b (patch)
tree34b779052372b867a15fd5374ecc96f3f86e0692 /perl-install
parent62d041fbb09b04859c159b7435e45f891c447871 (diff)
downloaddrakx-d67d1856ab717c9a0b00487b815314084a4fa34b.tar
drakx-d67d1856ab717c9a0b00487b815314084a4fa34b.tar.gz
drakx-d67d1856ab717c9a0b00487b815314084a4fa34b.tar.bz2
drakx-d67d1856ab717c9a0b00487b815314084a4fa34b.tar.xz
drakx-d67d1856ab717c9a0b00487b815314084a4fa34b.zip
(set_text): fix "cleanups"
Diffstat (limited to 'perl-install')
-rw-r--r--perl-install/ugtk2.pm10
1 files changed, 4 insertions, 6 deletions
diff --git a/perl-install/ugtk2.pm b/perl-install/ugtk2.pm
index 6119d9881..1f43bdb4c 100644
--- a/perl-install/ugtk2.pm
+++ b/perl-install/ugtk2.pm
@@ -1642,12 +1642,10 @@ sub get_text {
sub set_text {
my ($w, $val) = @_;
- find_index {
- if ($_ eq $val) {
- $w->set_active($::i);
- 1;
- }
- } @{$w->{strings}};
+ eval {
+ my $val_index = find_index { $_ eq $val } @{$w->{strings}};
+ $w->set_active($val_index);
+ };
}