ObjFW  Diff

Differences From Artifact [5097d3765b]:

To Artifact [4a0b7f4d80]:


523
524
525
526
527
528
529



530
531
532
533
534
535
536
}

- (void)deleteTrailingWhitespaces
{
	size_t length = [self length];
	ssize_t i;




	for (i = length - 1; i >= 0; i--) {
		of_unichar_t c = [self characterAtIndex: i];

		if (c != ' '  && c != '\t' && c != '\n' && c != '\r' &&
		    c != '\f')
			break;
	}







>
>
>







523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
}

- (void)deleteTrailingWhitespaces
{
	size_t length = [self length];
	ssize_t i;

	if (length - 1 > SSIZE_MAX)
		@throw [OFOutOfRangeException exception];

	for (i = length - 1; i >= 0; i--) {
		of_unichar_t c = [self characterAtIndex: i];

		if (c != ' '  && c != '\t' && c != '\n' && c != '\r' &&
		    c != '\f')
			break;
	}