add check for invalid handle.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@7795 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
		| @@ -1102,6 +1102,10 @@ USBKeyboardUnregisterKeyNotify ( | ||||
|   if (NotificationHandle == NULL) { | ||||
|     return EFI_INVALID_PARAMETER; | ||||
|   }   | ||||
|  | ||||
|   if (((KEYBOARD_CONSOLE_IN_EX_NOTIFY *) NotificationHandle)->Signature != USB_KB_CONSOLE_IN_EX_NOTIFY_SIGNATURE) { | ||||
|     return EFI_INVALID_PARAMETER; | ||||
|   }  | ||||
|    | ||||
|   UsbKeyboardDevice = TEXT_INPUT_EX_USB_KB_DEV_FROM_THIS (This); | ||||
|    | ||||
|   | ||||
		Reference in New Issue
	
	Block a user