From: kgv Date: Sat, 13 Dec 2014 12:00:07 +0000 (+0300) Subject: 0025608: TKernel, NCollection_UtfIterator - fix iteration of surrogate pairs in UTF-16 X-Git-Tag: V6_9_0_beta~222 X-Git-Url: http://git.dev.opencascade.org/gitweb/?a=commitdiff_plain;h=656ec77a10dd36ca66a5c8a1d6ea3e0cf093ed9e;p=occt-copy.git 0025608: TKernel, NCollection_UtfIterator - fix iteration of surrogate pairs in UTF-16 --- diff --git a/src/NCollection/NCollection_UtfIterator.lxx b/src/NCollection/NCollection_UtfIterator.lxx index 9b0025b64a..9c66c054a1 100755 --- a/src/NCollection/NCollection_UtfIterator.lxx +++ b/src/NCollection/NCollection_UtfIterator.lxx @@ -114,7 +114,7 @@ void NCollection_UtfIterator::readUTF16() if (aChar >= UTF16_SURROGATE_HIGH_START && aChar <= UTF16_SURROGATE_HIGH_END) { - Standard_Utf32Char aChar2 = *myPosition; + const Standard_Utf32Char aChar2 = *myPosNext; // complete the surrogate pair if (aChar2 >= UTF16_SURROGATE_LOW_START && aChar2 <= UTF16_SURROGATE_LOW_END)