diff options
-rw-r--r-- | perl-install/fs.pm | 2 | ||||
-rw-r--r-- | perl-install/partition_table.pm | 6 |
2 files changed, 6 insertions, 2 deletions
diff --git a/perl-install/fs.pm b/perl-install/fs.pm index f20aaf849..8f7b45809 100644 --- a/perl-install/fs.pm +++ b/perl-install/fs.pm @@ -240,7 +240,7 @@ sub prepare_write_fstab { } } - my $type = type2fs($_); + my $type = type2fs($_, 'auto'); my $dev = $_->{device_LABEL} ? $_->{device_LABEL} : diff --git a/perl-install/partition_table.pm b/perl-install/partition_table.pm index ef9e29038..a4120d0bb 100644 --- a/perl-install/partition_table.pm +++ b/perl-install/partition_table.pm @@ -226,7 +226,11 @@ sub important_types() { difference2(\@l, \@bad_types); } -sub type2fs { $type2fs{$_[0]{type}} || $_[0]{type} } +sub type2fs { + my ($part, $o_default) = @_; + my $type = $part->{type}; + $type2fs{$type} || $type =~ /^(\d+)$/ && $o_default || $type; +} sub fs2type { $fs2type{$_[0]} || $_[0] } sub type2name { $types{$_[0]} || $_[0] } sub name2type { |