use wxStrnlen() and add NULL-checks in wxMsgCatalogFile::FillHash for safer handling of corrupted MO files (closes #3151)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@58106 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -234,7 +234,8 @@ bool MyApp::OnInit()
|
||||
wxLocale::AddCatalogLookupPathPrefix(wxT("."));
|
||||
|
||||
// Initialize the catalogs we'll be using
|
||||
m_locale.AddCatalog(wxT("internat"));
|
||||
if (!m_locale.AddCatalog(wxT("internat")))
|
||||
wxLogError(_("Couldn't find/load the 'internat' catalog."));
|
||||
|
||||
// this catalog is installed in standard location on Linux systems and
|
||||
// shows that you may make use of the standard message catalogs as well
|
||||
|
Reference in New Issue
Block a user