summaryrefslogtreecommitdiffstats
path: root/perl-install
diff options
context:
space:
mode:
Diffstat (limited to 'perl-install')
-rw-r--r--perl-install/install_any.pm2
-rw-r--r--perl-install/partition_table_raw.pm2
2 files changed, 2 insertions, 2 deletions
diff --git a/perl-install/install_any.pm b/perl-install/install_any.pm
index ba088f414..00a4e4f34 100644
--- a/perl-install/install_any.pm
+++ b/perl-install/install_any.pm
@@ -948,7 +948,7 @@ sub getHds {
goto getHds;
}
if (!$::testing) {
- @$hds = grep { partition_table_raw::test_for_bad_drives($_) } @$hds;
+ @$hds = grep { eval { partition_table_raw::test_for_bad_drives($_) }; !$@ } @$hds;
}
$ok = fsedit::verifyHds($hds, $flags->{readonly}, $ok)
diff --git a/perl-install/partition_table_raw.pm b/perl-install/partition_table_raw.pm
index bbeaaa5ad..a56ff7648 100644
--- a/perl-install/partition_table_raw.pm
+++ b/perl-install/partition_table_raw.pm
@@ -141,7 +141,7 @@ sub test_for_bad_drives {
my $sector = $hd->{geom}{sectors} - 1;
- local *F; openit($hd, *F, 2) or return;
+ local *F; openit($hd, *F, 2) or die "can't open device";
my $seek = sub {
c::lseek_sector(fileno(F), $sector, 0) or die "seeking to sector $sector failed";