* util/getroot.c (find_root_devices_from_poolname): Handle vdevs

with full paths.
This commit is contained in:
Richard Laager 2012-02-27 17:42:48 +01:00 committed by Vladimir 'phcoder' Serbinenko
parent a414bd1565
commit 897b741978
2 changed files with 9 additions and 1 deletions

View file

@ -1,3 +1,8 @@
2012-02-27 Richard Laager <rlaager@wiktel.com>
* util/getroot.c (find_root_devices_from_poolname): Handle vdevs
with full paths.
2012-02-27 Richard Laager <rlaager@wiktel.com>
* util/getroot.c (grub_find_root_devices_from_mountinfo): Add missing

View file

@ -383,6 +383,9 @@ find_root_devices_from_poolname (char *poolname)
devices = xrealloc (devices, sizeof (devices[0])
* devices_allocated);
}
if (name[0] == '/')
devices[ndevices++] = xstrdup (name);
else
devices[ndevices++] = xasprintf ("/dev/%s", name);
}
break;