summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--l10ntools/source/lngmerge.cxx4
-rw-r--r--l10ntools/source/stringmerge.cxx1
2 files changed, 3 insertions, 2 deletions
diff --git a/l10ntools/source/lngmerge.cxx b/l10ntools/source/lngmerge.cxx
index 71f68effccdf..812c43667b35 100644
--- a/l10ntools/source/lngmerge.cxx
+++ b/l10ntools/source/lngmerge.cxx
@@ -269,7 +269,7 @@ sal_Bool LngParser::Merge(
rtl::OString sText1( sLang );
sText1 += " = \"";
// escape quotes, unescape double escaped quotes fdo#56648
- sText1 += sNewText.replaceAll("\"","\\\"").replaceAll("\\\\\"","\\\"");
+ sText1 += sNewText.replaceAll("\"","\\\"").replaceAll("\\\\\"","\\\"").replaceAll("\'","\\\'").replaceAll("\\\\\'","\\\'");
sText1 += "\"";
*pLine = sText1;
Text[ sLang ] = sNewText;
@@ -307,7 +307,7 @@ sal_Bool LngParser::Merge(
sLine += sCur;
sLine += " = \"";
// escape quotes, unescape double escaped quotes fdo#56648
- sLine += sNewText.replaceAll("\"","\\\"").replaceAll("\\\\\"","\\\"");
+ sLine += sNewText.replaceAll("\"","\\\"").replaceAll("\\\\\"","\\\"").replaceAll("\'","\\\'").replaceAll("\\\\\'","\\\'");
sLine += "\"";
nLastLangPos++;
diff --git a/l10ntools/source/stringmerge.cxx b/l10ntools/source/stringmerge.cxx
index 71909d9dbe72..26aabcb12e40 100644
--- a/l10ntools/source/stringmerge.cxx
+++ b/l10ntools/source/stringmerge.cxx
@@ -161,6 +161,7 @@ void StringParser::Merge(
{
OString sNewText;
pEntrys->GetText( sNewText, STRING_TYP_TEXT, m_sLang );
+ sNewText = sNewText.replaceAll("\"",""").replaceAll("\\\\\"","\\\"").replaceAll("\'","'").replaceAll("\\\\\'","\\\'");
xmlNodeSetContent(
pCurrent,
xmlEncodeSpecialChars( NULL,