diff options
author | Michael Brown <mcb30@ipxe.org> | 2020-12-08 15:52:25 +0000 |
---|---|---|
committer | Michael Brown <mcb30@ipxe.org> | 2020-12-08 15:52:25 +0000 |
commit | e3eedb0be581b7f3df70e8150c7adfcf275506b8 (patch) | |
tree | b793cf4f8f8aa4ecef263ab1dc508b6f36727689 | |
parent | 39f5293492f351a274940d0ba2624ecb242b3c9b (diff) | |
download | ipxe-e3eedb0be581b7f3df70e8150c7adfcf275506b8.tar.gz |
[efi] Avoid using potentially uninitialised driver name in veto checks
Signed-off-by: Michael Brown <mcb30@ipxe.org>
-rw-r--r-- | src/interface/efi/efi_veto.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/interface/efi/efi_veto.c b/src/interface/efi/efi_veto.c index ad501f262..6ff7898e9 100644 --- a/src/interface/efi/efi_veto.c +++ b/src/interface/efi/efi_veto.c @@ -518,8 +518,10 @@ static int efi_veto_find ( EFI_HANDLE driver, const char *manufacturer, /* Get driver name, if available */ if ( wtf.wtf && ( ( efirc = wtf.wtf->GetDriverName ( wtf.wtf, "eng", - &name ) != 0 ) ) ) { - /* Ignore failure; is not required to be present */ + &name ) == 0 ) ) ) { + /* Driver has a name */ + } else { + /* Ignore failure; name is not required to be present */ name = NULL; } |