applying 1960600 (avoid dereferencing lc if it hasn't been set)

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_8_BRANCH@53502 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Stefan Csomor
2008-05-09 04:48:24 +00:00
parent aba0599409
commit 554ddc6197

View File

@@ -2332,14 +2332,16 @@ void wxLocale::AddCatalogLookupPathPrefix(const wxString& prefix)
break ;
default :
break ;
}
for ( i = 0; i < count; i++ )
{
if ( ms_languagesDB->Item(i).CanonicalName == lc )
{
break;
}
}
}
if ( !lc )
return wxLANGUAGE_UNKNOWN;
for ( i = 0; i < count; i++ )
{
if ( ms_languagesDB->Item(i).CanonicalName == lc )
{
break;
}
}
#elif defined(__WIN32__)
LCID lcid = GetUserDefaultLCID();