mirror of
https://git.proxmox.com/git/grub2
synced 2025-07-27 09:39:58 +00:00
kern/efi: Fix memory leak on failure
Free the memory allocated to name before returning on failure. Fixes: CID 296222 Signed-off-by: Darren Kenny <darren.kenny@oracle.com> Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
This commit is contained in:
parent
d06161b035
commit
ed286ceba6
@ -410,6 +410,7 @@ grub_efi_get_filename (grub_efi_device_path_t *dp0)
|
||||
{
|
||||
grub_error (GRUB_ERR_OUT_OF_RANGE,
|
||||
"malformed EFI Device Path node has length=%d", len);
|
||||
grub_free (name);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user