From 179997f9696ad71eaad5fc696d0b430e46230612 Mon Sep 17 00:00:00 2001 From: plagman Date: Thu, 3 Dec 2009 04:41:09 +0000 Subject: [PATCH] Don't overflow scantoasc[] with high scancodes. This makes the 'T' key work in the console on my laptop. git-svn-id: https://svn.eduke32.com/eduke32@1548 1a8010ca-5511-0410-912e-c29ae57300e0 --- polymer/eduke32/build/src/winlayer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/polymer/eduke32/build/src/winlayer.c b/polymer/eduke32/build/src/winlayer.c index a153bebfd..9a2643baf 100644 --- a/polymer/eduke32/build/src/winlayer.c +++ b/polymer/eduke32/build/src/winlayer.c @@ -4366,7 +4366,7 @@ static LRESULT CALLBACK WndProcCallback(HWND hWnd, UINT uMsg, WPARAM wParam, LPA case WM_CHAR: if (((keyasciififoend+1)&(KEYFIFOSIZ-1)) == keyasciififoplc) return 0; if ((keyasciififoend - keyasciififoplc) > 0) return 0; - if (Btolower(scantoasc[OSD_OSDKey()]) == Btolower((uint8_t)wParam)) return 0; + if ((OSD_OSDKey() < 128) && (Btolower(scantoasc[OSD_OSDKey()]) == Btolower((uint8_t)wParam))) return 0; if (!OSD_HandleChar((uint8_t)wParam)) return 0; keyasciififo[keyasciififoend] = (uint8_t)wParam; keyasciififoend = ((keyasciififoend+1)&(KEYFIFOSIZ-1));