summaryrefslogtreecommitdiffstats
path: root/perl-install/any.pm
diff options
context:
space:
mode:
authorThierry Vignaud <thierry.vignaud@gmail.com>2016-07-17 10:35:09 +0200
committerThierry Vignaud <thierry.vignaud@gmail.com>2016-07-17 15:59:47 +0200
commitfbc399721879746f2cc69208dba3a42b290b0a7d (patch)
treecf95d56c48e4e31d8e79aa898c6d010f7e91f228 /perl-install/any.pm
parentafb0a1e932d2566e2118211168baa62d66385141 (diff)
downloaddrakx-fbc399721879746f2cc69208dba3a42b290b0a7d.tar
drakx-fbc399721879746f2cc69208dba3a42b290b0a7d.tar.gz
drakx-fbc399721879746f2cc69208dba3a42b290b0a7d.tar.bz2
drakx-fbc399721879746f2cc69208dba3a42b290b0a7d.tar.xz
drakx-fbc399721879746f2cc69208dba3a42b290b0a7d.zip
grub2: fix not being able to edit default cmdline
Keep default append value (aka /etc/default/grub's GRUB_CMDLINE_LINUX_DEFAULT into {default_append} variable) Always use the value passed as now write_grub2_sysconfig() is only called after having offered to display the default cmdline value On first run (during installer) or when migrating from grub-legacy or lilo, we get the first entry's parameters Thus resolving mga#18952
Diffstat (limited to 'perl-install/any.pm')
-rw-r--r--perl-install/any.pm4
1 files changed, 2 insertions, 2 deletions
diff --git a/perl-install/any.pm b/perl-install/any.pm
index 6809a522f..d25ac5ab8 100644
--- a/perl-install/any.pm
+++ b/perl-install/any.pm
@@ -622,7 +622,7 @@ sub setupBootloader__grub2 {
my $b2 = bootloader::read_grub2();
# get default parameters:
- my $append = $b->{entries}[0]{append} ||= bootloader::get_grub2_append($b2);
+ my $append = $b->{default_append} || $b->{entries}[0]{append} || bootloader::get_grub2_append($b2);
my $default = $b2->{default};
require Xconfig::resolution_and_depth;
@@ -654,7 +654,7 @@ sub setupBootloader__grub2 {
$b->{entries} = $b2->{entries};
$b->{default} = $default;
$b->{vga} = ref($vga) ? $vga->{bios} : $vga;
- first(@{$b->{entries}})->{append} = $append;
+ $b->{default_append} = $append;
if ($os_prober) {
$in->do_pkgs->ensure_is_installed('os-prober', '/usr/bin/os-prober');
} else {