https://git.reactos.org/?p=reactos.git;a=commitdiff;h=774c3b3c9226cebd00302…
commit 774c3b3c9226cebd00302926db2ac8fa6665ecd2
Author: Katayama Hirofumi MZ <katayama.hirofumi.mz(a)gmail.com>
AuthorDate: Wed Oct 19 17:50:47 2022 +0900
Commit: Katayama Hirofumi MZ <katayama.hirofumi.mz(a)gmail.com>
CommitDate: Wed Oct 19 17:52:31 2022 +0900
[USER32] CliGetPreloadKeyboardLayouts: Use _ultow
CORE-11700
---
win32ss/user/user32/windows/input.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/win32ss/user/user32/windows/input.c b/win32ss/user/user32/windows/input.c
index 7c2a3992278..d3b7e114ba9 100644
--- a/win32ss/user/user32/windows/input.c
+++ b/win32ss/user/user32/windows/input.c
@@ -369,7 +369,7 @@ BOOL FASTCALL CliGetImeHotKeysFromRegistry(VOID)
VOID APIENTRY CliGetPreloadKeyboardLayouts(PBYTE pbFlags)
{
- WCHAR szValueName[12], szValue[16];
+ WCHAR szValueName[33], szValue[16];
UNICODE_STRING ustrValue;
DWORD dwKL, cbValue, dwType;
UINT iNumber;
@@ -382,7 +382,7 @@ VOID APIENTRY CliGetPreloadKeyboardLayouts(PBYTE pbFlags)
for (iNumber = 1; iNumber < 1000; ++iNumber)
{
- StringCchPrintfW(szValueName, _countof(szValueName), L"%u", iNumber);
+ _ultow(iNumber, szValueName, 10);
cbValue = sizeof(szValue);
error = RegQueryValueExW(hKey, szValueName, NULL, &dwType, (LPBYTE)szValue,
&cbValue);