bug-grub
[Top][All Lists]
Advanced

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

[bug #29250] GRUB_HIDDEN_TIMEOUT may cause double timeout count


From: Mario Vazquez
Subject: [bug #29250] GRUB_HIDDEN_TIMEOUT may cause double timeout count
Date: Thu, 18 Mar 2010 07:38:37 +0000
User-agent: Mozilla/5.0 (compatible; Konqueror/4.4; Linux) KHTML/4.4.1 (like Gecko) Chakra/1.0

URL:
  <http://savannah.gnu.org/bugs/?29250>

                 Summary: GRUB_HIDDEN_TIMEOUT may cause double timeout count
                 Project: GNU GRUB
            Submitted by: mariovazq
            Submitted on: Thu 18 Mar 2010 07:38:37 AM GMT
                Category: None
                Severity: Major
                Priority: 5 - Normal
              Item Group: Software Error
                  Status: None
                 Privacy: Public
             Assigned to: None
         Originator Name: Mario Vazquez
        Originator Email: address@hidden
             Open/Closed: Open
         Discussion Lock: Any
                 Release: 
                 Release: 1.98
         Reproducibility: Every Time
         Planned Release: None

    _______________________________________________________

Details:

Currently in grub 1.98 if a user enables the GRUB_HIDDEN_TIMEOUT entry in
/etc/default/grub. The following code will be executed from
/etc/grub.d/00_header.

if sleep$verbose --interruptible ${GRUB_HIDDEN_TIMEOUT} ; then
  set timeout=${GRUB_TIMEOUT}
fi

The problem with that code is that hidding the menu enables both the timeout
entry in the if line, and the one inside the if.  Even if the user removes or
comments the GRUB_TIMEOUT entry, that entry is defined in 00_header.  That
means that GRUB_TIMEOUT will have the value of 5, even if the user comments
it.

Since the definition of GRUB_TIMEOUT cannot be removed from 00_header without
causing other issues, my recommendation is to set that line to 0.

if sleep$verbose --interruptible ${GRUB_HIDDEN_TIMEOUT} ; then
  set timeout=0
fi

Included is a patch that do that.

How to reproduce the error:
 1. Enable the hidden timeout entry to any value in /etc/default/grub. 
 2. Reboot
 3. Either wait for the hidden counter to finish, or interrupt it, and you
will get your menu with another counter.  The second counter is from
GRUB_TIMEOUT entry.

Note: my tests apparently using ESC key to cancel, the second counter is not
displayed.  But with other keys like Return, it is visible.



    _______________________________________________________

File Attachments:


-------------------------------------------------------
Date: Thu 18 Mar 2010 07:38:37 AM GMT  Name: hidden-timeout-fix.patch  Size:
406B   By: mariovazq
GRUB_TIMEOUT removal patch
<http://savannah.gnu.org/bugs/download.php?file_id=19971>

    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?29250>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/





reply via email to

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