bug-grub
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] Fix savedefault after menu editing


From: adrian15
Subject: Re: [PATCH] Fix savedefault after menu editing
Date: Tue, 02 May 2006 17:52:35 +0200
User-agent: Mozilla Thunderbird 1.0.7 (Windows/20050923)

Pavel Roskin wrote:
Hello!

This bug has annoyed me for years, so I decided to finally fix it.  I
know, GRUB is GRUB Legacy now, but it there will be another release, it
should have this fix.  Even if there will be no release, maybe this
patch will be applied by the OS vendors.
If I find it useful I will add it to Super Grub Disk (One of its components its a fork of Grub 0.97)

When using "e" to edit the commands followed by "b" to boot the edited
commands, the behavior of "savedefault" (if in was the command list)
seemed unpredictable.  GRUB could suddenly select and boot a different
entry on the next boot.

As it turns out, "savedefault" was remembering the entry number in the
submenu used for editing the command.  So, if e.g. the second command
was under the cursor, GRUB would default to the second entry on the next
boot.  The fix is, of course, to calculate the current entry only in the
top level menu - either when booting or when calling a submenu.

I've never came across this problem although I understand it.
I don't know if it will be difficult to integrate it into my Grub fork now that it has the call and back commands (equivalent to source command in bash)

adrian15




reply via email to

[Prev in Thread] Current Thread [Next in Thread]