* util/getroot.c (grub_guess_root_devices): Don't canonicalise
/dev/root and /dev/dm-*.
This commit is contained in:
parent
00d41dee71
commit
de89d33847
2 changed files with 15 additions and 4 deletions
|
@ -1,3 +1,8 @@
|
|||
2012-06-02 Vladimir Serbinenko <phcoder@gmail.com>
|
||||
|
||||
* util/getroot.c (grub_guess_root_devices): Don't canonicalise
|
||||
/dev/root and /dev/dm-*.
|
||||
|
||||
2012-06-02 Vladimir Serbinenko <phcoder@gmail.com>
|
||||
|
||||
* grub-core/normal/menu_entry.c (update_screen): Fix loop condition to
|
||||
|
|
|
@ -1036,10 +1036,16 @@ grub_guess_root_devices (const char *dir)
|
|||
{
|
||||
char *tmp = *cur;
|
||||
int root, dm;
|
||||
*cur = canonicalize_file_name (tmp);
|
||||
if (*cur == NULL)
|
||||
grub_util_error (_("failed to get canonical path of %s"), tmp);
|
||||
free (tmp);
|
||||
if (strcmp (*cur, "/dev/root") == 0
|
||||
|| strncmp (*cur, "/dev/dm-", sizeof ("/dev/dm-") - 1) == 0)
|
||||
*cur = tmp;
|
||||
else
|
||||
{
|
||||
*cur = canonicalize_file_name (tmp);
|
||||
if (*cur == NULL)
|
||||
grub_util_error (_("failed to get canonical path of %s"), tmp);
|
||||
free (tmp);
|
||||
}
|
||||
root = (strcmp (*cur, "/dev/root") == 0);
|
||||
dm = (strncmp (*cur, "/dev/dm-", sizeof ("/dev/dm-") - 1) == 0);
|
||||
if (!dm && !root)
|
||||
|
|
Loading…
Reference in a new issue