mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-11-11 07:11:39 +00:00
Fix potential buffer overruns in sdlayer
git-svn-id: https://svn.eduke32.com/eduke32@7080 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
1f8b23152e
commit
75e141ec81
1 changed files with 2 additions and 2 deletions
|
@ -808,7 +808,7 @@ int32_t initinput(void)
|
|||
if (!keytranslation[i])
|
||||
continue;
|
||||
|
||||
Bstrncpyz(g_keyNameTable[keytranslation[i]], SDL_GetKeyName(SDL_SCANCODE_TO_KEYCODE(i)), sizeof(g_keyNameTable[i]));
|
||||
Bstrncpyz(g_keyNameTable[keytranslation[i]], SDL_GetKeyName(SDL_SCANCODE_TO_KEYCODE(i)), sizeof(g_keyNameTable[0]));
|
||||
}
|
||||
|
||||
if (!SDL_InitSubSystem(SDL_INIT_JOYSTICK))
|
||||
|
@ -2098,7 +2098,7 @@ int32_t handleevents_pollsdl(void)
|
|||
if (OSD_HandleChar(code))
|
||||
keyBufferInsert(code);
|
||||
}
|
||||
} while (j < SDL_TEXTINPUTEVENT_TEXT_SIZE && ev.text.text[++j]);
|
||||
} while (j < SDL_TEXTINPUTEVENT_TEXT_SIZE-1 && ev.text.text[++j]);
|
||||
break;
|
||||
|
||||
case SDL_KEYDOWN:
|
||||
|
|
Loading…
Reference in a new issue