summaryrefslogtreecommitdiff
path: root/i18npool/source/transliteration/ignoreIandEfollowedByYa_ja_JP.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'i18npool/source/transliteration/ignoreIandEfollowedByYa_ja_JP.cxx')
-rw-r--r--i18npool/source/transliteration/ignoreIandEfollowedByYa_ja_JP.cxx9
1 files changed, 4 insertions, 5 deletions
diff --git a/i18npool/source/transliteration/ignoreIandEfollowedByYa_ja_JP.cxx b/i18npool/source/transliteration/ignoreIandEfollowedByYa_ja_JP.cxx
index 4ecfbf00be9f..bcc25f84de3c 100644
--- a/i18npool/source/transliteration/ignoreIandEfollowedByYa_ja_JP.cxx
+++ b/i18npool/source/transliteration/ignoreIandEfollowedByYa_ja_JP.cxx
@@ -29,9 +29,8 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_i18npool.hxx"
-// prevent internal compiler error with MSVC6SP3
#include <utility>
-
+#include <comphelper/string.hxx>
#include <i18nutil/oneToOneMapping.hxx>
#define TRANSLITERATION_IandEfollowedByYa_ja_JP
#include <transliteration_Ignore.hxx>
@@ -87,8 +86,8 @@ ignoreIandEfollowedByYa_ja_JP::folding( const OUString& inStr, sal_Int32 startPo
throw(RuntimeException)
{
// Create a string buffer which can hold nCount + 1 characters.
- // The reference count is 0 now.
- rtl_uString * newStr = x_rtl_uString_new_WithLength( nCount ); // defined in x_rtl_ustring.h
+ // The reference count is 1 now.
+ rtl_uString * newStr = comphelper::string::rtl_uString_alloc(nCount);
sal_Unicode * dst = newStr->buffer;
const sal_Unicode * src = inStr.getStr() + startPos;
@@ -145,7 +144,7 @@ ignoreIandEfollowedByYa_ja_JP::folding( const OUString& inStr, sal_Int32 startPo
newStr->length = sal_Int32(dst - newStr->buffer);
if (useOffset)
offset.realloc(newStr->length);
- return OUString( newStr ); // defined in rtl/usrting. The reference count is increased from 0 to 1.
+ return OUString(newStr, SAL_NO_ACQUIRE); // take ownership
}
} } } }