summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2004-09-27 03:41:29 +0000
committerPascal Rigaux <pixel@mandriva.com>2004-09-27 03:41:29 +0000
commitc9c3e3687bb2f4e21c76e5c1ea73540db86d3d47 (patch)
treefbcaba2224f7f7aa717f546d8fa19521121f82b1
parent7fd4b90ff1acd3e8f08442a0c54ab737e4db4d57 (diff)
downloaddrakx-backup-do-not-use-c9c3e3687bb2f4e21c76e5c1ea73540db86d3d47.tar
drakx-backup-do-not-use-c9c3e3687bb2f4e21c76e5c1ea73540db86d3d47.tar.gz
drakx-backup-do-not-use-c9c3e3687bb2f4e21c76e5c1ea73540db86d3d47.tar.bz2
drakx-backup-do-not-use-c9c3e3687bb2f4e21c76e5c1ea73540db86d3d47.tar.xz
drakx-backup-do-not-use-c9c3e3687bb2f4e21c76e5c1ea73540db86d3d47.zip
don't call compute_nb_cylinders() before checking {sectors} and {heads} are valid
-rw-r--r--perl-install/partition_table/dos.pm4
1 files changed, 2 insertions, 2 deletions
diff --git a/perl-install/partition_table/dos.pm b/perl-install/partition_table/dos.pm
index d364b0030..ca64d3946 100644
--- a/perl-install/partition_table/dos.pm
+++ b/perl-install/partition_table/dos.pm
@@ -130,12 +130,12 @@ sub geometry_from_edd {
my $geom = { sectors => 0 + cat_("$edd_dir/legacy_sectors_per_track"),
heads => 1 + cat_("$edd_dir/legacy_max_head"),
from_edd => 1 };
+ is_geometry_valid_for_the_partition_table($hd, $geom) or return;
partition_table::raw::compute_nb_cylinders($geom, $hd->{totalsectors});
log::l("geometry_from_edd $hd->{device} $hd->{volume_id}: " . geometry_to_string($geom));
- member($geom->{heads}, @valid_nb_heads) && member($geom->{sectors}, @valid_nb_sectors)
- && $geom;
+ $geom;
}