* grub-core/lib/legacy_parse.c (grub_legacy_parse): Correctly handle

hexadecimal.
This commit is contained in:
Vladimir 'phcoder' Serbinenko 2011-05-05 01:27:54 +02:00
parent 664889a69c
commit ee5614b7f8
2 changed files with 9 additions and 1 deletions

View file

@ -1,3 +1,8 @@
2011-05-05 Vladimir Serbinenko <phcoder@gmail.com>
* grub-core/lib/legacy_parse.c (grub_legacy_parse): Correctly handle
hexadecimal.
2011-05-05 Vladimir Serbinenko <phcoder@gmail.com>
* grub-core/efiemu/main.c (grub_efiemu_load_file): Return grub_errno

View file

@ -680,7 +680,10 @@ grub_legacy_parse (const char *buf, char **entryname, char **suffix)
int base = 10;
brk = curarg;
if (brk[0] == '0' && brk[1] == 'x')
base = 16;
{
base = 16;
brk += 2;
}
else if (brk[0] == '0')
base = 8;
for (; *brk && brk < curarg + curarglen; brk++)