X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/48a1108eb87970373e1b1d5debeeaedd8d1916ea..f51723055aa4334a355a19e87bb2b478b4204d15:/src/os2/fontenum.cpp diff --git a/src/os2/fontenum.cpp b/src/os2/fontenum.cpp index 1af60107aa..fdb1f4af11 100644 --- a/src/os2/fontenum.cpp +++ b/src/os2/fontenum.cpp @@ -120,7 +120,7 @@ void wxFontEnumeratorHelper::DoEnumerate() #ifdef __WIN32__ LOGFONT lf; lf.lfCharSet = m_charset; - wxStrncpy(lf.lfFaceName, m_facename, WXSIZEOF(lf.lfFaceName)); + wxStrlcpy(lf.lfFaceName, m_facename, WXSIZEOF(lf.lfFaceName)); lf.lfPitchAndFamily = 0; ::EnumFontFamiliesEx(hDC, &lf, (wxFONTENUMPROC)wxFontEnumeratorProc, (LPARAM)this, 0) ;