summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sw/source/filter/ascii/parasc.cxx1
1 files changed, 1 insertions, 0 deletions
diff --git a/sw/source/filter/ascii/parasc.cxx b/sw/source/filter/ascii/parasc.cxx
index ddc685595c86..11c7f2ed4931 100644
--- a/sw/source/filter/ascii/parasc.cxx
+++ b/sw/source/filter/ascii/parasc.cxx
@@ -324,6 +324,7 @@ sal_uLong SwASCIIParser::ReadChars()
sal_Size nNewLen = lGCount, nCntBytes;
aWork.reset(new sal_Unicode[nNewLen + 1]); // add 1 for '\0'
sal_Unicode* pBuf = aWork.get();
+ pBuf[nNewLen] = 0; // ensure '\0'
nNewLen = rtl_convertTextToUnicode( hConverter, hContext,
pArr, lGCount, pBuf, nNewLen,