loader.efi: efi_readkey_ex needs to key despite the shift status or toggle status
From UEFI specification 2.8, page 434: "It should also be noted that certain input devices may not be able to produce shift or toggle state information, and in those cases the high order bit in the respective Toggle and Shift state fields should not be active." But we still need to check for ScanCode and UnicodeChar. PR: 242660 Reported by: Trond Endrestol MFC after: 1 week
This commit is contained in:
parent
359e4dba07
commit
ade8a0f1d1
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=355844
@ -1126,12 +1126,16 @@ efi_readkey_ex(void)
|
||||
kp->UnicodeChar++;
|
||||
}
|
||||
}
|
||||
}
|
||||
/*
|
||||
* The shift state and/or toggle state may not be valid,
|
||||
* but we still can have ScanCode or UnicodeChar.
|
||||
*/
|
||||
if (kp->ScanCode == 0 && kp->UnicodeChar == 0)
|
||||
return (false);
|
||||
keybuf_inschar(kp);
|
||||
return (true);
|
||||
}
|
||||
}
|
||||
return (false);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user