From 17447eb71f813f2f02eeacefdcd5594fa4f0632f Mon Sep 17 00:00:00 2001 From: Florent Villard Date: Tue, 18 Nov 2003 10:06:38 +0000 Subject: stupid undef of vga at the wrong place --- scripts/detect-resolution | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'scripts/detect-resolution') diff --git a/scripts/detect-resolution b/scripts/detect-resolution index 9ea3519..6a777c1 100755 --- a/scripts/detect-resolution +++ b/scripts/detect-resolution @@ -9,7 +9,7 @@ # add better detection thanks to Olivier Blin idea to use argument from # make_boot_splash. -#use strict; +use strict; my (%main, %entry, $vga, $initrd); if ($ARGV[0]) { @@ -41,7 +41,6 @@ sub detect_from_loader { } $vga ||= $entry{$main{default}}{vga}; $vga ||= $main{vga} - print "VGA ($vga) main $main{vga} initrd $initrd ($main{initrd}{$initrd})\n"; } sub parse_grub_conf { my ($title); @@ -75,7 +74,7 @@ sub parse_grub_conf { sub parse_lilo_conf { my $lilo_conf="/etc/lilo.conf"; - my ($vga, $label); + my ($vga, $label, $loc_initrd); return if not -f $lilo_conf; open F, $lilo_conf or die "Can't open $lilo_conf\n"; while () { @@ -87,13 +86,13 @@ sub parse_lilo_conf { $loc_initrd = $1 if m,initrd=(?:.*/)?(.*),; $entry{$label}{vga} = $vga if ($label && $vga); if (/image/) { - undef $vga,$label; if ($loc_initrd && $label && $vga) { $entry{$label}{initrd} = $loc_initrd; if (!$main{initrd}{$loc_initrd} || $main{default} eq $label) { $main{initrd}{$loc_initrd} = $vga } } + undef $vga,$label; } } if ($loc_initrd && $label && $vga) { -- cgit v1.2.1