From 92cf36e56d9a3cbd3aeb4f611598c04945f7386e Mon Sep 17 00:00:00 2001 From: Pascal Rigaux Date: Wed, 16 Jan 2002 18:20:35 +0000 Subject: fix cancel on scsi module loading --- perl-install/any.pm | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'perl-install') diff --git a/perl-install/any.pm b/perl-install/any.pm index 98755a944..8ea7cad80 100644 --- a/perl-install/any.pm +++ b/perl-install/any.pm @@ -613,6 +613,11 @@ sub setup_thiskind { return @l if $auto && (@l || !$at_least_one); } @l = map { $_->{description} } @l; + + if ($at_least_one && !@l) { + push @l, load_module($in, $type) || return; + } + while (1) { (my $msg_type = $type) =~ s/\|.*//; my $msg = @l ? @@ -622,8 +627,7 @@ sub setup_thiskind { my $opt = [ __("Yes"), __("No") ]; push @$opt, __("See hardware info") if $::expert; - my $r = "Yes"; - $r = $in->ask_from_list_('', $msg, $opt, "No") || die 'already displayed' unless $at_least_one && @l == 0; + my $r = $in->ask_from_list_('', $msg, $opt, "No") or die 'already displayed'; if ($r eq "No") { return @l } if ($r eq "Yes") { push @l, load_module($in, $type) || next; -- cgit v1.2.1