summaryrefslogtreecommitdiffstats
path: root/perl-install
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2004-07-05 05:58:27 +0000
committerPascal Rigaux <pixel@mandriva.com>2004-07-05 05:58:27 +0000
commit51fd51c2f560620d0e5c73a824d7677661f9c385 (patch)
treefd587ea47a47d52ee13aae238c37aa9414473c59 /perl-install
parentcfa7a2a5576e1723c50bf22448360f7527694b9a (diff)
downloaddrakx-51fd51c2f560620d0e5c73a824d7677661f9c385.tar
drakx-51fd51c2f560620d0e5c73a824d7677661f9c385.tar.gz
drakx-51fd51c2f560620d0e5c73a824d7677661f9c385.tar.bz2
drakx-51fd51c2f560620d0e5c73a824d7677661f9c385.tar.xz
drakx-51fd51c2f560620d0e5c73a824d7677661f9c385.zip
create rationalize_options() and use it (bugzilla #3525)
more checks should be done in this function, and used at more places (but where?)
Diffstat (limited to 'perl-install')
-rw-r--r--perl-install/fs.pm17
-rw-r--r--perl-install/fsedit.pm3
2 files changed, 17 insertions, 3 deletions
diff --git a/perl-install/fs.pm b/perl-install/fs.pm
index 148f6cf23..06a864f25 100644
--- a/perl-install/fs.pm
+++ b/perl-install/fs.pm
@@ -483,6 +483,19 @@ user,exec,dev,suid )."),
);
}
+
+sub rationalize_options {
+ my ($part) = @_;
+
+ my ($options, $unknown) = mount_options_unpack($part);
+
+ if (!isThisFs('reiserfs', $part)) {
+ $options->{notail} = 0;
+ }
+
+ mount_options_pack($part, $options, $unknown);
+}
+
sub set_default_options {
my ($part, %opts) = @_;
#- opts are: useSupermount security iocharset codepage
@@ -540,8 +553,6 @@ sub set_default_options {
}
if (isThisFs('reiserfs', $part)) {
$options->{notail} = 1;
- } else {
- $options->{notail} = 0;
}
if (isLoopback($part) && !isSwap($part)) { #- no need for loop option for swap files
$options->{loop} = 1;
@@ -561,6 +572,8 @@ sub set_default_options {
}
mount_options_pack($part, $options, $unknown);
+
+ rationalize_options($part);
}
sub set_all_default_options {
diff --git a/perl-install/fsedit.pm b/perl-install/fsedit.pm
index 921d96d63..89e999b01 100644
--- a/perl-install/fsedit.pm
+++ b/perl-install/fsedit.pm
@@ -771,7 +771,8 @@ sub change_type {
$part->{mntpoint} = '' if isRawLVM({ type => $type }) || isRawRAID({ type => $type });
$part->{type} = $type;
$part->{notFormatted} = 1;
- $part->{isFormatted} = 0;
+ $part->{isFormatted} = 0;
+ fs::rationalize_options($part);
}
sub rescuept($) {