summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorHeinrich Schuchardt <xypron.glpk@gmx.de>2018-02-18 02:08:00 +0300
committerAlexander Graf <agraf@suse.de>2018-04-04 12:00:06 +0300
commiteb68b4ef31cd7d0fe08becda7ac1e56b45f9054a (patch)
treefd616f0eddde61394a2dc05bad053168389f33f5 /lib
parent0fb4169e2819d6950708154789287e4ad9b40a91 (diff)
downloadu-boot-eb68b4ef31cd7d0fe08becda7ac1e56b45f9054a.tar.xz
efi_loader: check parameter in InstallConfigurationTable
Check that parameter guid is not NULL. This avoids a possible NULL pointer exception. Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Signed-off-by: Alexander Graf <agraf@suse.de>
Diffstat (limited to 'lib')
-rw-r--r--lib/efi_loader/efi_boottime.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/efi_loader/efi_boottime.c b/lib/efi_loader/efi_boottime.c
index 3cee8d607c..9ca2e8161e 100644
--- a/lib/efi_loader/efi_boottime.c
+++ b/lib/efi_loader/efi_boottime.c
@@ -1333,6 +1333,9 @@ efi_status_t efi_install_configuration_table(const efi_guid_t *guid, void *table
{
int i;
+ if (!guid)
+ return EFI_INVALID_PARAMETER;
+
/* Check for guid override */
for (i = 0; i < systab.nr_tables; i++) {
if (!guidcmp(guid, &efi_conf_table[i].guid)) {