2010-02-14 Vladimir Serbinenko <phcoder@gmail.com>
Prevent unknown commands from stopping menuentry execution. * script/execute.c (grub_script_execute_cmdline): Print error after unknown command.
This commit is contained in:
parent
095f5f82f7
commit
bc028f2f86
2 changed files with 10 additions and 2 deletions
|
@ -1,3 +1,10 @@
|
|||
2010-02-14 Vladimir Serbinenko <phcoder@gmail.com>
|
||||
|
||||
Prevent unknown commands from stopping menuentry execution.
|
||||
|
||||
* script/execute.c (grub_script_execute_cmdline): Print error after
|
||||
unknown command.
|
||||
|
||||
2010-02-14 Vladimir Serbinenko <phcoder@gmail.com>
|
||||
|
||||
* fs/i386/pc/pxe.c (GRUB_MOD_INIT): Fix typo.
|
||||
|
|
|
@ -100,8 +100,7 @@ grub_script_execute_cmdline (struct grub_script_cmd *cmd)
|
|||
grubcmd = grub_command_find (cmdname);
|
||||
if (! grubcmd)
|
||||
{
|
||||
/* Shouldn't happen but precaution is good. */
|
||||
grub_print_error ();
|
||||
grub_errno = GRUB_ERR_NONE;
|
||||
|
||||
/* It's not a GRUB command, try all functions. */
|
||||
func = grub_script_function_find (cmdname);
|
||||
|
@ -126,6 +125,8 @@ grub_script_execute_cmdline (struct grub_script_cmd *cmd)
|
|||
grub_snprintf (errnobuf, sizeof (errnobuf), "%d", grub_errno);
|
||||
grub_env_set ("?", errnobuf);
|
||||
|
||||
grub_print_error ();
|
||||
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue