Differences From Artifact [39a9726c51]:
- File
src/OFMutableString.m
— part of check-in
[44f45c2e35]
at
2017-01-09 17:36:36
on branch trunk
— Update copyright
Forgot to add 2017, even though I already did quite some changes in
2017. (user: js, size: 13696) [annotate] [blame] [check-ins using]
To Artifact [b4559a9fab]:
- File src/OFMutableString.m — part of check-in [696bc0d890] at 2017-03-12 00:58:48 on branch trunk — OFMutableString: Check more arguments for nil (user: js, size: 13788) [annotate] [blame] [check-ins using]
︙ | ︙ | |||
521 522 523 524 525 526 527 528 529 530 531 532 533 534 | { void *pool = objc_autoreleasePoolPush(), *pool2; const of_unichar_t *characters; const of_unichar_t *searchCharacters = [string characters]; size_t searchLength = [string length]; size_t replacementLength = [replacement length]; if (range.length > SIZE_MAX - range.location || range.location + range.length > [self length]) @throw [OFOutOfRangeException exception]; if (searchLength > range.length) { objc_autoreleasePoolPop(pool); return; | > > > | 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 | { void *pool = objc_autoreleasePoolPush(), *pool2; const of_unichar_t *characters; const of_unichar_t *searchCharacters = [string characters]; size_t searchLength = [string length]; size_t replacementLength = [replacement length]; if (string == nil || replacement == nil) @throw [OFInvalidArgumentException exception]; if (range.length > SIZE_MAX - range.location || range.location + range.length > [self length]) @throw [OFOutOfRangeException exception]; if (searchLength > range.length) { objc_autoreleasePoolPop(pool); return; |
︙ | ︙ |