Fix boundary error in replacement function

This commit is contained in:
rfm 2024-11-20 17:46:08 +00:00
parent 9189f1bca6
commit 91124f3247

View file

@ -166,7 +166,7 @@ UTextNSMutableStringReplace(UText *ut,
// Setting the chunk length to 0 here forces UTextNSStringAccess to fetch
// the data from the string object.
ut->chunkLength = 0;
UTextNSStringAccess(ut, r.location + [replacement length] + 1, TRUE);
UTextNSStringAccess(ut, r.location + [replacement length], TRUE);
ut->chunkOffset++;
[replacement release];