acpi: fix memory leak

Found by: Coverity scan.
CID: 96673
This commit is contained in:
Andrei Borzenkov 2016-01-12 20:26:30 +03:00
parent 66768b99f1
commit 8fe17d91af

View file

@ -593,6 +593,9 @@ grub_cmd_acpi (struct grub_extcmd_context *ctxt, int argc, char **args)
if (! table->addr) if (! table->addr)
{ {
free_tables (); free_tables ();
grub_free (exclude);
grub_free (load_only);
grub_free (table);
return grub_errno; return grub_errno;
} }
table->next = acpi_tables; table->next = acpi_tables;