diff --git a/icu4c/source/i18n/ucol.cpp b/icu4c/source/i18n/ucol.cpp index bb84a5c11d..3d2f288abc 100644 --- a/icu4c/source/i18n/ucol.cpp +++ b/icu4c/source/i18n/ucol.cpp @@ -981,7 +981,7 @@ uint32_t getSpecialPrevCE(const UCollator *coll, uint32_t CE, } UChar *sourceCopy = source->string; UChar *targetCopy = source->writableBuffer; - while (sourceCopy <= strend) { + while (sourceCopy < strend) { if (UCOL_ISTHAIPREVOWEL(*sourceCopy) && /* This is the combination that needs to be swapped */ UCOL_ISTHAIBASECONSONANT(*(sourceCopy + 1))) {