diff options
Diffstat (limited to 'perl-install/partition_table_dos.pm')
-rw-r--r-- | perl-install/partition_table_dos.pm | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/perl-install/partition_table_dos.pm b/perl-install/partition_table_dos.pm index 305aa862b..1b25a8f0b 100644 --- a/perl-install/partition_table_dos.pm +++ b/perl-install/partition_table_dos.pm @@ -8,7 +8,6 @@ use vars qw(@ISA); use common qw(:common :system :file); use partition_table_raw; -use partition_table; use c; my @fields = qw(active start_head start_sec start_cyl type end_head end_sec end_cyl start size); @@ -68,15 +67,8 @@ sub read($$) { sub write($$$;$) { my ($hd, $sector, $pt) = @_; - #- handle testing for writing partition table on file only! - local *F; - if ($::testing) { - my $file = "/tmp/partition_table_$hd->{device}"; - open F, ">$file" or die "error opening test file $file"; - } else { - partition_table_raw::openit($hd, *F, 2) or die "error opening device $hd->{device} for writing"; - c::lseek_sector(fileno(F), $sector, $offset) or return 0; - } + local *F; partition_table_raw::openit($hd, *F, 2) or die "error opening device $hd->{device} for writing"; + c::lseek_sector(fileno(F), $sector, $offset) or return 0; @$pt == $nb_primary or die "partition table does not have $nb_primary entries"; foreach (@$pt) { |