ICU-12379 Add assertion check to internal function parameter value.
X-SVN-Rev: 38524
This commit is contained in:
parent
076db669c4
commit
29e0435a01
@ -2603,7 +2603,11 @@ void RegexCompile::findCaseInsensitiveStarters(UChar32 c, UnicodeSet *starterCh
|
||||
|
||||
// End of machine generated data.
|
||||
|
||||
if (u_hasBinaryProperty(c, UCHAR_CASE_SENSITIVE)) {
|
||||
if (c < UCHAR_MIN_VALUE || c > UCHAR_MAX_VALUE) {
|
||||
// This function should never be called with an invalid input character.
|
||||
U_ASSERT(FALSE);
|
||||
starterChars->clear();
|
||||
} else if (u_hasBinaryProperty(c, UCHAR_CASE_SENSITIVE)) {
|
||||
UChar32 caseFoldedC = u_foldCase(c, U_FOLD_CASE_DEFAULT);
|
||||
starterChars->set(caseFoldedC, caseFoldedC);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user