1
0
mirror of https://xff.cz/git/u-boot/ synced 2025-09-01 16:52:14 +02:00

efi_loader: copy GUID in InstallProtocolInterface()

InstallProtocolInterface() is called with a pointer to the protocol GUID.
There is not guarantee that the memory used by the caller for the protocol
GUID stays allocated. To play it safe the GUID should be copied to U-Boot's
internal structures.

Reported-by: Joerie de Gram <j.de.gram@gmail.com>
Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
This commit is contained in:
Heinrich Schuchardt
2022-03-09 19:56:23 +01:00
parent f95104825a
commit 66028930da
3 changed files with 9 additions and 9 deletions

View File

@@ -342,7 +342,7 @@ struct efi_open_protocol_info_item {
*/
struct efi_handler {
struct list_head link;
const efi_guid_t *guid;
const efi_guid_t guid;
void *protocol_interface;
struct list_head open_infos;
};