diff options
author | Thierry Vignaud <tv@mageia.org> | 2012-05-23 18:27:28 +0000 |
---|---|---|
committer | Thierry Vignaud <tv@mageia.org> | 2012-05-23 18:27:28 +0000 |
commit | 61a889fa68242a97db3951c63d49db3ebb2bb7b4 (patch) | |
tree | 26f7580e4a98e68f4e43dd38bece567970222191 | |
parent | f0110566b41d1c9499bf30edb2eb6f1c7c345bd8 (diff) | |
download | drakx-backup-do-not-use-61a889fa68242a97db3951c63d49db3ebb2bb7b4.tar drakx-backup-do-not-use-61a889fa68242a97db3951c63d49db3ebb2bb7b4.tar.gz drakx-backup-do-not-use-61a889fa68242a97db3951c63d49db3ebb2bb7b4.tar.bz2 drakx-backup-do-not-use-61a889fa68242a97db3951c63d49db3ebb2bb7b4.tar.xz drakx-backup-do-not-use-61a889fa68242a97db3951c63d49db3ebb2bb7b4.zip |
(_format_raw) factorize with similar code
-rw-r--r-- | perl-install/diskdrake/interactive.pm | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/perl-install/diskdrake/interactive.pm b/perl-install/diskdrake/interactive.pm index af71d894f..8a4d9bb9c 100644 --- a/perl-install/diskdrake/interactive.pm +++ b/perl-install/diskdrake/interactive.pm @@ -568,13 +568,7 @@ First remove a primary partition and create an extended partition.")); if ($::isStandalone) { fs::format::check_package_is_installed_format($in->do_pkgs, $p->{fs_type}) or log::l("Missing package"); } - if ($::expert && !member($p->{fs_type}, 'reiserfs', 'xfs', 'hfs', 'ntfs', 'ntfs-3g')) { - $p->{toFormatCheck} = $in->ask_yesorno(N("Confirmation"), N("Check for bad blocks?")); - } - $p->{isFormatted} = 0; #- force format; - # Wait for the newly created device to appear before formatting it - my ($_w, $wait_message) = $in->wait_message_with_progress_bar; - fs::format::part($all_hds, $p, $wait_message) unless isRawLVM($p); + _format_raw($in, $p, $all_hds, isRawLVM($p)); } warn_if_renumbered($in, $hd); @@ -1294,13 +1288,14 @@ sub format_ { } sub _format_raw { - my ($in, $part, $all_hds) = @_; + my ($in, $part, $all_hds, $o_skip) = @_; if ($::expert && !member($part->{fs_type}, 'reiserfs', 'xfs', 'hfs', 'ntfs', 'ntfs-3g')) { $part->{toFormatCheck} = $in->ask_yesorno(N("Confirmation"), N("Check for bad blocks?")); } $part->{isFormatted} = 0; #- force format; + # Wait for the newly created device to appear before formatting it my ($_w, $wait_message) = $in->wait_message_with_progress_bar; - fs::format::part($all_hds, $part, $wait_message); + fs::format::part($all_hds, $part, $wait_message) if !$o_skip; 1; } |