summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2012-04-02 14:52:47 +0100
committerCaolán McNamara <caolanm@redhat.com>2012-04-02 14:53:50 +0100
commit791f27683311e487947b0464a0cb132b19fd0e12 (patch)
tree583510f8f0e591ac9a1f5b83048a004eb0d6c4b5
parentecf2926ce13db8244a198de9f69bcefcae68b4b6 (diff)
Resolves: fdo#48129 maLangStr can have trailing nulls
-rw-r--r--rsc/source/parser/rscibas.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/rsc/source/parser/rscibas.cxx b/rsc/source/parser/rscibas.cxx
index 40ee8ddf4997..df233cc3c06a 100644
--- a/rsc/source/parser/rscibas.cxx
+++ b/rsc/source/parser/rscibas.cxx
@@ -105,8 +105,8 @@ void RscLangEnum::Init( RscNameTable& rNames )
pLangEntry->mnLang,
MsLangId::convertLanguageToIsoByteString( pLangEntry->mnLang ).getStr() );
#endif
- rtl::OString aLang = pLangEntry->maLangStr;
- rtl::OString aCountry = pLangEntry->maCountry;
+ rtl::OString aLang(pLangEntry->maLangStr, strlen(pLangEntry->maLangStr));
+ rtl::OString aCountry(pLangEntry->maCountry, strlen(pLangEntry->maCountry));
if ( aCountry.isEmpty() || aLang.equalsIgnoreAsciiCase(aCountry) )
{
SetConstant( rNames.Put( aLang.getStr(), CONSTNAME, mnLangId ), mnLangId );