commands/nativedisk: Add missing device_close.
Found by: Coverity scan.
This commit is contained in:
parent
72bbd8046a
commit
bd50aa323d
1 changed files with 2 additions and 0 deletions
|
@ -57,6 +57,7 @@ get_uuid (const char *name, char **uuid, int getnative)
|
||||||
if (!dev->disk)
|
if (!dev->disk)
|
||||||
{
|
{
|
||||||
grub_dprintf ("nativedisk", "Skipping non-disk\n");
|
grub_dprintf ("nativedisk", "Skipping non-disk\n");
|
||||||
|
grub_device_close (dev);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -90,6 +91,7 @@ get_uuid (const char *name, char **uuid, int getnative)
|
||||||
case GRUB_DISK_DEVICE_MEMDISK_ID:
|
case GRUB_DISK_DEVICE_MEMDISK_ID:
|
||||||
grub_dprintf ("nativedisk", "Skipping native disk %s\n",
|
grub_dprintf ("nativedisk", "Skipping native disk %s\n",
|
||||||
dev->disk->name);
|
dev->disk->name);
|
||||||
|
grub_device_close (dev);
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
/* FIXME: those probably need special handling. */
|
/* FIXME: those probably need special handling. */
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue