ObjFW  Check-in [41095bf7a1]

Overview
Comment:Fix three stupid warnings.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: 41095bf7a1d35d8c83e068ea8a2cff9bc6f0fd86ad754f12e7b6eb574c5d18ac
User & Date: js on 2009-01-05 02:18:36
Other Links: manifest | tags
Context
2009-01-05
22:18
Reworked OFList. check-in: 8ab6561840 user: js tags: trunk
02:18
Fix three stupid warnings. check-in: 41095bf7a1 user: js tags: trunk
01:31
Fix IPv6 test on win32, in case we're not crosscompiling.
Additionally, remove useless -D_REENTRANT (which had a typo and
was -D_RENTRANT and is added by acx_pthread.m4 anyway if it's needed).
check-in: 720661e1b3 user: js tags: trunk
Changes

Modified src/OFString.m from [922642403b] to [7c7b5b7fed].

414
415
416
417
418
419
420
421

422
423
424
425
426
427


428
429
430
431
432
433
434

435
436
437
438
439
440


441
442
443
444
414
415
416
417
418
419
420

421
422
423
424
425


426
427
428
429
430
431
432
433

434
435
436
437
438


439
440
441
442
443
444







-
+




-
-
+
+






-
+




-
-
+
+




	madvise(string, len, MADV_NORMAL);

	return self;
}

- upper
{
	size_t i = length;
	char *p = string + length;

	if (is_utf8)
		@throw [OFInvalidEncodingException newWithClass: [self class]];

	while (i--)
		string[i] = toupper(string[i]);
	while (--p >= string)
		*p = toupper((int)*p);

	return self;
}

- lower
{
	size_t i = length;
	char *p = string + length;

	if (is_utf8)
		@throw [OFInvalidEncodingException newWithClass: [self class]];

	while (i--)
		string[i] = tolower(string[i]);
	while (--p >= string)
		*p = tolower((int)*p);

	return self;
}
@end

Modified src/OFXMLFactory.m from [9148296a75] to [482f651e16].

106
107
108
109
110
111
112
113

114
115
116
117
118
119
120
106
107
108
109
110
111
112

113
114
115
116
117
118
119
120







-
+







	return ret;
}

+ (char*)createStanza: (const char*)name
	 withCloseTag: (BOOL)close
	      andData: (const char*)data, ...
{
	char *arg, *val, *xml, *esc_val;
	char *arg, *val, *xml, *esc_val = NULL;
	size_t i, len;
	va_list args;

	/* Start of tag */
	len = strlen(name);
	if (SIZE_MAX - len < 3)
		@throw [OFOutOfRangeException newWithClass: self];