From: Jan Janssen Date: Fri, 11 Feb 2022 12:17:23 +0000 (+0100) Subject: boot: Correctly check the return value of CheckEvent X-Git-Tag: v251-rc1~306 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ac3979abd7a38725b66c1ce0607fa905b3a3d782;p=thirdparty%2Fsystemd.git boot: Correctly check the return value of CheckEvent Fixes: #22428 --- diff --git a/src/boot/efi/console.c b/src/boot/efi/console.c index 3a0cf535e15..cd5c8b63480 100644 --- a/src/boot/efi/console.c +++ b/src/boot/efi/console.c @@ -147,7 +147,7 @@ EFI_STATUS console_key_read(UINT64 *key, UINT64 timeout_usec) { } return EFI_NOT_READY; - } else if (BS->CheckEvent(ST->ConIn->WaitForKey)) { + } else if (!EFI_ERROR(BS->CheckEvent(ST->ConIn->WaitForKey))) { EFI_INPUT_KEY k; err = ST->ConIn->ReadKeyStroke(ST->ConIn, &k);