[KBSWITCH] Use StringCchCopy instead of lstrcpyn

This commit is contained in:
Katayama Hirofumi MZ 2022-08-24 10:23:51 +09:00
parent 0991cedca7
commit 3892252bc5

View file

@ -59,7 +59,7 @@ CreateTrayIcon(LPTSTR szLCID)
ZeroMemory(&lf, sizeof(lf));
lf.lfHeight = -11;
lf.lfCharSet = ANSI_CHARSET;
lstrcpyn(lf.lfFaceName, _T("Tahoma"), ARRAYSIZE(lf.lfFaceName));
StringCchCopy(lf.lfFaceName, ARRAYSIZE(lf.lfFaceName), _T("Tahoma"));
hFont = CreateFontIndirect(&lf);
SetRect(&rect, 0, 0, CX_ICON, CY_ICON);