i18nutil/source/utility/unicode.cxx | 12 ++++++------ include/i18nutil/unicode.hxx | 1 - 2 files changed, 6 insertions(+), 7 deletions(-)
New commits: commit 49f11e4a5cb60993e1421ccae831c810d494c4d7 Author: Stephan Bergmann <sberg...@redhat.com> Date: Tue Sep 20 11:23:03 2016 +0200 Related cid#1371289: Improve code to not depend on missing move assignment Change-Id: I6f0b8247b6757ddee158bd870473b749f22e7671 diff --git a/i18nutil/source/utility/unicode.cxx b/i18nutil/source/utility/unicode.cxx index 0ae9ab7..9c489b1 100644 --- a/i18nutil/source/utility/unicode.cxx +++ b/i18nutil/source/utility/unicode.cxx @@ -1210,7 +1210,7 @@ sal_uInt32 ToggleUnicodeCodepoint::CharsToDelete() OUString ToggleUnicodeCodepoint::ReplacementString() { OUString sIn = StringToReplace(); - maOutput = ""; + OUStringBuffer output = ""; sal_Int32 nUPlus = sIn.indexOf("U+"); // convert from hex notation to glyph if( nUPlus != -1 || (sIn.getLength() > 1 && mbIsHexString) ) @@ -1224,13 +1224,13 @@ OUString ToggleUnicodeCodepoint::ReplacementString() while( nUPlus > 0 ) { nUnicode = sIn.copy(0, nUPlus).toUInt32(16); - maOutput.appendUtf32( nUnicode ); + output.appendUtf32( nUnicode ); sIn = sIn.copy(nUPlus+2); nUPlus = sIn.indexOf("U+"); } nUnicode = sIn.toUInt32(16); - maOutput.appendUtf32( nUnicode ); + output.appendUtf32( nUnicode ); } // convert from glyph to hex notation else @@ -1242,11 +1242,11 @@ OUString ToggleUnicodeCodepoint::ReplacementString() //pad with zeros - minimum length of 4. for( sal_Int32 i = 4 - aTmp.getLength(); i > 0; --i ) aTmp.insert( 0,"0" ); - maOutput.append( "U+" ); - maOutput.append( aTmp ); + output.append( "U+" ); + output.append( aTmp ); } } - return maOutput.toString(); + return output.toString(); } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/include/i18nutil/unicode.hxx b/include/i18nutil/unicode.hxx index 318c7807..ec51716 100644 --- a/include/i18nutil/unicode.hxx +++ b/include/i18nutil/unicode.hxx @@ -72,7 +72,6 @@ class I18NUTIL_DLLPUBLIC ToggleUnicodeCodepoint { private: OUStringBuffer maInput; - OUStringBuffer maOutput; OUStringBuffer maUtf16; OUStringBuffer maCombining; bool mbAllowMoreChars = true; _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits