hw/xwin: Remove a pointless OS version check in winInstallKeyboardHookLL()

Checking for OS later than NT4 SP3 (which we didn't do correctly anyhow,
just checking for NT) is pointless when other code in hw/xwin assumes at
least NT 5.0

Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Colin Harrison <colin.harrison@virgin.net>
This commit is contained in:
Jon TURNEY 2012-02-23 22:32:09 +00:00
parent 0ed0d39790
commit 3568d4af4f

View File

@ -133,24 +133,6 @@ winKeyboardMessageHookLL(int iCode, WPARAM wParam, LPARAM lParam)
Bool
winInstallKeyboardHookLL(void)
{
OSVERSIONINFO osvi = { 0 };
/* Get operating system version information */
osvi.dwOSVersionInfoSize = sizeof(osvi);
GetVersionEx(&osvi);
/* Branch on platform ID */
switch (osvi.dwPlatformId) {
case VER_PLATFORM_WIN32_NT:
/* Low-level is supported on NT 4.0 SP3+ only */
/* TODO: Return FALSE on NT 4.0 with no SP, SP1, or SP2 */
break;
case VER_PLATFORM_WIN32_WINDOWS:
/* Low-level hook is not supported on non-NT */
return FALSE;
}
/* Install the hook only once */
if (!g_hhookKeyboardLL)
g_hhookKeyboardLL = SetWindowsHookEx(WH_KEYBOARD_LL,