summaryrefslogtreecommitdiff
path: root/lib/efi_loader
diff options
context:
space:
mode:
authorHeinrich Schuchardt <[email protected]>2025-07-08 13:14:35 +0200
committerHeinrich Schuchardt <[email protected]>2025-07-26 07:37:03 +0200
commit7e2506e3a247c787a9ad4b4db00bc8e6a348df90 (patch)
tree3e3d34e5c3c8bfb5222e5f32a95a19191375bffc /lib/efi_loader
parentaa703a816a62deb876a1e77ccff030a7cc60f344 (diff)
efi_loader: correct EFI_DEBUG_TABLE_ENTRY_SIZE
With the current code we allocate to little memory when adding entries to the EFI_DEBUG_INFO_TABLE and we fail to correctly move entries when an entry is removed. EFI_DEBUG_TABLE_ENTRY_SIZE must be the size of an entry in the EFI_DEBUG_INFO_TABLE, not the size of a pointer. Fixes: 146546138af5 ("efi: add EFI_DEBUG_IMAGE_INFO for debug") Addresses-Coverity-ID: CID 569498: Code maintainability issues (SIZEOF_MISMATCH) Reviewed-by: Ilias Apalodimas <[email protected]> Signed-off-by: Heinrich Schuchardt <[email protected]>
Diffstat (limited to 'lib/efi_loader')
-rw-r--r--lib/efi_loader/efi_debug_support.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/efi_loader/efi_debug_support.c b/lib/efi_loader/efi_debug_support.c
index 186bdbce750..490b0bb7088 100644
--- a/lib/efi_loader/efi_debug_support.c
+++ b/lib/efi_loader/efi_debug_support.c
@@ -22,7 +22,7 @@ struct efi_debug_image_info_table_header efi_m_debug_info_table_header = {
*/
static u32 efi_m_max_table_entries;
-#define EFI_DEBUG_TABLE_ENTRY_SIZE (sizeof(union efi_debug_image_info *))
+#define EFI_DEBUG_TABLE_ENTRY_SIZE (sizeof(union efi_debug_image_info))
/**
* efi_initialize_system_table_pointer() - Initialize system table pointer