X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/48a1108eb87970373e1b1d5debeeaedd8d1916ea..404b319a85dadd7decf7a5a5331020520031a41c:/src/os2/fontenum.cpp?ds=sidebyside 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) ;