summaryrefslogtreecommitdiffstats
path: root/perl-install/partition_table
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2008-03-25 17:19:28 +0000
committerPascal Rigaux <pixel@mandriva.com>2008-03-25 17:19:28 +0000
commit77ddcd64e50ace0bafd4e29188bc8a7a73fb73fe (patch)
tree5a3253249d622a2dc4606e01f91ab0cc9788e066 /perl-install/partition_table
parentec1309c90f14e6e8aafe26693ef0d2927a3ac0ec (diff)
downloaddrakx-77ddcd64e50ace0bafd4e29188bc8a7a73fb73fe.tar
drakx-77ddcd64e50ace0bafd4e29188bc8a7a73fb73fe.tar.gz
drakx-77ddcd64e50ace0bafd4e29188bc8a7a73fb73fe.tar.bz2
drakx-77ddcd64e50ace0bafd4e29188bc8a7a73fb73fe.tar.xz
drakx-77ddcd64e50ace0bafd4e29188bc8a7a73fb73fe.zip
- partitioning wizard lirary:
o allow "Use free space" if there is an extended partition even if all primary partitions are used (#38804) (*old* bug!)
Diffstat (limited to 'perl-install/partition_table')
-rw-r--r--perl-install/partition_table/gpt.pm1
-rw-r--r--perl-install/partition_table/raw.pm6
2 files changed, 7 insertions, 0 deletions
diff --git a/perl-install/partition_table/gpt.pm b/perl-install/partition_table/gpt.pm
index 81967d07e..5c46e25ca 100644
--- a/perl-install/partition_table/gpt.pm
+++ b/perl-install/partition_table/gpt.pm
@@ -213,6 +213,7 @@ sub raw_removed {
my ($_hd, $raw) = @_;
@$raw = grep { $_->{size} && $_->{pt_type} } @$raw;
}
+sub can_add { &can_raw_add }
sub can_raw_add {
my ($hd) = @_;
@{$hd->{primary}{raw}} < $hd->{primary}{info}{nbPartitions};
diff --git a/perl-install/partition_table/raw.pm b/perl-install/partition_table/raw.pm
index 6edc26507..44b4b6e01 100644
--- a/perl-install/partition_table/raw.pm
+++ b/perl-install/partition_table/raw.pm
@@ -192,6 +192,12 @@ sub openit {
my $F; sysopen($F, $hd->{file}, $o_mode || 0) && $F;
}
+sub can_add {
+ my ($hd) = @_;
+ !$_->{size} && !$_->{pt_type} || isExtended($_) and return 1 foreach @{$hd->{primary}{raw}};
+ 0;
+}
+
sub raw_removed {
my ($_hd, $_raw) = @_;
}