ObjFW  Check-in [67e7d1e222]

Overview
Comment:Move path methods from OFFile to OFString.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: 67e7d1e2229d461851a5876dc99b06de3aa9e6008771947c8c9fdc06c1563417
User & Date: js on 2011-03-22 13:10:23
Other Links: manifest | tags
Context
2011-03-22
20:57
Fix table generator. check-in: 371086d5b9 user: js tags: trunk
13:10
Move path methods from OFFile to OFString. check-in: 67e7d1e222 user: js tags: trunk
01:03
Clang is a bit more pedantic with -Wshorten-64-to-32. check-in: b2c9efebcf user: js tags: trunk
Changes

Modified ObjFW.xcodeproj/project.pbxproj from [688ffd4e1c] to [136e25e82c].

133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
		4BDF37B51338055600F9A81A /* config.h in Headers */ = {isa = PBXBuildFile; fileRef = 4BDF37B41338055600F9A81A /* config.h */; };
		4BF33AFB133807590059CEF7 /* ObjFW.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 4B3D23761337FBC800DD29B8 /* ObjFW.framework */; };
		4BF33AFC133807A20059CEF7 /* OFArrayTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B6EF66E1235358D0076B512 /* OFArrayTests.m */; };
		4BF33AFD133807A20059CEF7 /* OFBlockTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 4BE5F0E412DF4259005C7A0C /* OFBlockTests.m */; };
		4BF33AFE133807A20059CEF7 /* OFDataArrayTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B6EF66F1235358D0076B512 /* OFDataArrayTests.m */; };
		4BF33AFF133807A20059CEF7 /* OFDateTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 4BE5F0E512DF4259005C7A0C /* OFDateTests.m */; };
		4BF33B00133807A20059CEF7 /* OFDictionaryTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B6EF6701235358D0076B512 /* OFDictionaryTests.m */; };
		4BF33B01133807A20059CEF7 /* OFFileTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B6EF6711235358D0076B512 /* OFFileTests.m */; };
		4BF33B02133807A20059CEF7 /* OFHTTPRequestTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B3D23701337FB7500DD29B8 /* OFHTTPRequestTests.m */; };
		4BF33B03133807A20059CEF7 /* OFListTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B6EF6721235358D0076B512 /* OFListTests.m */; };
		4BF33B04133807A20059CEF7 /* OFMD5HashTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B6EF6731235358D0076B512 /* OFMD5HashTests.m */; };
		4BF33B05133807A20059CEF7 /* OFNumberTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B6EF6741235358D0076B512 /* OFNumberTests.m */; };
		4BF33B06133807A20059CEF7 /* OFObjectTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B6EF6751235358D0076B512 /* OFObjectTests.m */; };
		4BF33B07133807A20059CEF7 /* OFPluginTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B6EF6761235358D0076B512 /* OFPluginTests.m */; };
		4BF33B08133807A20059CEF7 /* OFSHA1HashTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B6EF6771235358D0076B512 /* OFSHA1HashTests.m */; };







<







133
134
135
136
137
138
139

140
141
142
143
144
145
146
		4BDF37B51338055600F9A81A /* config.h in Headers */ = {isa = PBXBuildFile; fileRef = 4BDF37B41338055600F9A81A /* config.h */; };
		4BF33AFB133807590059CEF7 /* ObjFW.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 4B3D23761337FBC800DD29B8 /* ObjFW.framework */; };
		4BF33AFC133807A20059CEF7 /* OFArrayTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B6EF66E1235358D0076B512 /* OFArrayTests.m */; };
		4BF33AFD133807A20059CEF7 /* OFBlockTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 4BE5F0E412DF4259005C7A0C /* OFBlockTests.m */; };
		4BF33AFE133807A20059CEF7 /* OFDataArrayTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B6EF66F1235358D0076B512 /* OFDataArrayTests.m */; };
		4BF33AFF133807A20059CEF7 /* OFDateTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 4BE5F0E512DF4259005C7A0C /* OFDateTests.m */; };
		4BF33B00133807A20059CEF7 /* OFDictionaryTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B6EF6701235358D0076B512 /* OFDictionaryTests.m */; };

		4BF33B02133807A20059CEF7 /* OFHTTPRequestTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B3D23701337FB7500DD29B8 /* OFHTTPRequestTests.m */; };
		4BF33B03133807A20059CEF7 /* OFListTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B6EF6721235358D0076B512 /* OFListTests.m */; };
		4BF33B04133807A20059CEF7 /* OFMD5HashTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B6EF6731235358D0076B512 /* OFMD5HashTests.m */; };
		4BF33B05133807A20059CEF7 /* OFNumberTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B6EF6741235358D0076B512 /* OFNumberTests.m */; };
		4BF33B06133807A20059CEF7 /* OFObjectTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B6EF6751235358D0076B512 /* OFObjectTests.m */; };
		4BF33B07133807A20059CEF7 /* OFPluginTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B6EF6761235358D0076B512 /* OFPluginTests.m */; };
		4BF33B08133807A20059CEF7 /* OFSHA1HashTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B6EF6771235358D0076B512 /* OFSHA1HashTests.m */; };
226
227
228
229
230
231
232


233
234
235
236
237
238
239
/* Begin PBXFileReference section */
		4B0108C910EB8C9300631877 /* OFEnumerator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = OFEnumerator.h; path = src/OFEnumerator.h; sourceTree = "<group>"; };
		4B0108CA10EB8C9300631877 /* OFEnumerator.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFEnumerator.m; path = src/OFEnumerator.m; sourceTree = "<group>"; };
		4B0D249411DFAA3D00ED6FFC /* OFXMLElementBuilder.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = OFXMLElementBuilder.h; path = src/OFXMLElementBuilder.h; sourceTree = "<group>"; };
		4B0D249511DFAA3D00ED6FFC /* OFXMLElementBuilder.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFXMLElementBuilder.m; path = src/OFXMLElementBuilder.m; sourceTree = "<group>"; };
		4B175C1D116D130B003C99CB /* OFApplication.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = OFApplication.h; path = src/OFApplication.h; sourceTree = "<group>"; };
		4B175C1E116D130B003C99CB /* OFApplication.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFApplication.m; path = src/OFApplication.m; sourceTree = "<group>"; };


		4B23CA8A133811610047A1D9 /* TestPlugin.impl */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.dylib"; includeInIndex = 0; path = TestPlugin.impl; sourceTree = BUILT_PRODUCTS_DIR; };
		4B3D236D1337FB5800DD29B8 /* base64.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = base64.h; path = src/base64.h; sourceTree = "<group>"; };
		4B3D236E1337FB5800DD29B8 /* base64.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = base64.m; path = src/base64.m; sourceTree = "<group>"; };
		4B3D23701337FB7500DD29B8 /* OFHTTPRequestTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFHTTPRequestTests.m; path = tests/OFHTTPRequestTests.m; sourceTree = "<group>"; };
		4B3D23761337FBC800DD29B8 /* ObjFW.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = ObjFW.framework; sourceTree = BUILT_PRODUCTS_DIR; };
		4B3D23BB1337FC5800DD29B8 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = SOURCE_ROOT; };
		4B3D23EF1338008000DD29B8 /* mach_alias_list */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = mach_alias_list; path = src/mach_alias_list; sourceTree = SOURCE_ROOT; };







>
>







225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
/* Begin PBXFileReference section */
		4B0108C910EB8C9300631877 /* OFEnumerator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = OFEnumerator.h; path = src/OFEnumerator.h; sourceTree = "<group>"; };
		4B0108CA10EB8C9300631877 /* OFEnumerator.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFEnumerator.m; path = src/OFEnumerator.m; sourceTree = "<group>"; };
		4B0D249411DFAA3D00ED6FFC /* OFXMLElementBuilder.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = OFXMLElementBuilder.h; path = src/OFXMLElementBuilder.h; sourceTree = "<group>"; };
		4B0D249511DFAA3D00ED6FFC /* OFXMLElementBuilder.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFXMLElementBuilder.m; path = src/OFXMLElementBuilder.m; sourceTree = "<group>"; };
		4B175C1D116D130B003C99CB /* OFApplication.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = OFApplication.h; path = src/OFApplication.h; sourceTree = "<group>"; };
		4B175C1E116D130B003C99CB /* OFApplication.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFApplication.m; path = src/OFApplication.m; sourceTree = "<group>"; };
		4B19023A1338D6A2000374C9 /* Makefile */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.make; name = Makefile; path = src/Makefile; sourceTree = SOURCE_ROOT; };
		4B19023D1338D6D5000374C9 /* Makefile */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.make; name = Makefile; path = tests/Makefile; sourceTree = "<group>"; };
		4B23CA8A133811610047A1D9 /* TestPlugin.impl */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.dylib"; includeInIndex = 0; path = TestPlugin.impl; sourceTree = BUILT_PRODUCTS_DIR; };
		4B3D236D1337FB5800DD29B8 /* base64.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = base64.h; path = src/base64.h; sourceTree = "<group>"; };
		4B3D236E1337FB5800DD29B8 /* base64.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = base64.m; path = src/base64.m; sourceTree = "<group>"; };
		4B3D23701337FB7500DD29B8 /* OFHTTPRequestTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFHTTPRequestTests.m; path = tests/OFHTTPRequestTests.m; sourceTree = "<group>"; };
		4B3D23761337FBC800DD29B8 /* ObjFW.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = ObjFW.framework; sourceTree = BUILT_PRODUCTS_DIR; };
		4B3D23BB1337FC5800DD29B8 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = SOURCE_ROOT; };
		4B3D23EF1338008000DD29B8 /* mach_alias_list */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = mach_alias_list; path = src/mach_alias_list; sourceTree = SOURCE_ROOT; };
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
		4B6AF96C10A8D3E40003FB0A /* asprintf.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = asprintf.m; path = src/asprintf.m; sourceTree = "<group>"; };
		4B6AF96F10A8D40E0003FB0A /* iso_8859_15.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = iso_8859_15.m; path = src/iso_8859_15.m; sourceTree = "<group>"; };
		4B6AF97210A8D42E0003FB0A /* windows_1252.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = windows_1252.m; path = src/windows_1252.m; sourceTree = "<group>"; };
		4B6AF97310A8D4450003FB0A /* ObjFW.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ObjFW.h; path = src/ObjFW.h; sourceTree = "<group>"; };
		4B6EF66E1235358D0076B512 /* OFArrayTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFArrayTests.m; path = tests/OFArrayTests.m; sourceTree = SOURCE_ROOT; };
		4B6EF66F1235358D0076B512 /* OFDataArrayTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFDataArrayTests.m; path = tests/OFDataArrayTests.m; sourceTree = SOURCE_ROOT; };
		4B6EF6701235358D0076B512 /* OFDictionaryTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFDictionaryTests.m; path = tests/OFDictionaryTests.m; sourceTree = SOURCE_ROOT; };
		4B6EF6711235358D0076B512 /* OFFileTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFFileTests.m; path = tests/OFFileTests.m; sourceTree = SOURCE_ROOT; };
		4B6EF6721235358D0076B512 /* OFListTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFListTests.m; path = tests/OFListTests.m; sourceTree = SOURCE_ROOT; };
		4B6EF6731235358D0076B512 /* OFMD5HashTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFMD5HashTests.m; path = tests/OFMD5HashTests.m; sourceTree = SOURCE_ROOT; };
		4B6EF6741235358D0076B512 /* OFNumberTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFNumberTests.m; path = tests/OFNumberTests.m; sourceTree = SOURCE_ROOT; };
		4B6EF6751235358D0076B512 /* OFObjectTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFObjectTests.m; path = tests/OFObjectTests.m; sourceTree = SOURCE_ROOT; };
		4B6EF6761235358D0076B512 /* OFPluginTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFPluginTests.m; path = tests/OFPluginTests.m; sourceTree = SOURCE_ROOT; };
		4B6EF6771235358D0076B512 /* OFSHA1HashTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFSHA1HashTests.m; path = tests/OFSHA1HashTests.m; sourceTree = SOURCE_ROOT; };
		4B6EF6781235358D0076B512 /* OFStreamTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFStreamTests.m; path = tests/OFStreamTests.m; sourceTree = SOURCE_ROOT; };







<







286
287
288
289
290
291
292

293
294
295
296
297
298
299
		4B6AF96C10A8D3E40003FB0A /* asprintf.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = asprintf.m; path = src/asprintf.m; sourceTree = "<group>"; };
		4B6AF96F10A8D40E0003FB0A /* iso_8859_15.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = iso_8859_15.m; path = src/iso_8859_15.m; sourceTree = "<group>"; };
		4B6AF97210A8D42E0003FB0A /* windows_1252.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = windows_1252.m; path = src/windows_1252.m; sourceTree = "<group>"; };
		4B6AF97310A8D4450003FB0A /* ObjFW.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ObjFW.h; path = src/ObjFW.h; sourceTree = "<group>"; };
		4B6EF66E1235358D0076B512 /* OFArrayTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFArrayTests.m; path = tests/OFArrayTests.m; sourceTree = SOURCE_ROOT; };
		4B6EF66F1235358D0076B512 /* OFDataArrayTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFDataArrayTests.m; path = tests/OFDataArrayTests.m; sourceTree = SOURCE_ROOT; };
		4B6EF6701235358D0076B512 /* OFDictionaryTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFDictionaryTests.m; path = tests/OFDictionaryTests.m; sourceTree = SOURCE_ROOT; };

		4B6EF6721235358D0076B512 /* OFListTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFListTests.m; path = tests/OFListTests.m; sourceTree = SOURCE_ROOT; };
		4B6EF6731235358D0076B512 /* OFMD5HashTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFMD5HashTests.m; path = tests/OFMD5HashTests.m; sourceTree = SOURCE_ROOT; };
		4B6EF6741235358D0076B512 /* OFNumberTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFNumberTests.m; path = tests/OFNumberTests.m; sourceTree = SOURCE_ROOT; };
		4B6EF6751235358D0076B512 /* OFObjectTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFObjectTests.m; path = tests/OFObjectTests.m; sourceTree = SOURCE_ROOT; };
		4B6EF6761235358D0076B512 /* OFPluginTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFPluginTests.m; path = tests/OFPluginTests.m; sourceTree = SOURCE_ROOT; };
		4B6EF6771235358D0076B512 /* OFSHA1HashTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFSHA1HashTests.m; path = tests/OFSHA1HashTests.m; sourceTree = SOURCE_ROOT; };
		4B6EF6781235358D0076B512 /* OFStreamTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFStreamTests.m; path = tests/OFStreamTests.m; sourceTree = SOURCE_ROOT; };
405
406
407
408
409
410
411

412
413
414
415
416
417
418
			name = Products;
			sourceTree = "<group>";
		};
		4B3D23801337FBC800DD29B8 /* Supporting Files */ = {
			isa = PBXGroup;
			children = (
				4B3D23BB1337FC5800DD29B8 /* Info.plist */,

				4BDF37B41338055600F9A81A /* config.h */,
				4B3D23EF1338008000DD29B8 /* mach_alias_list */,
				4BD98C011338140B0048DD5B /* objfw-defs.h */,
			);
			name = "Supporting Files";
			path = ObjFW;
			sourceTree = "<group>";







>







405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
			name = Products;
			sourceTree = "<group>";
		};
		4B3D23801337FBC800DD29B8 /* Supporting Files */ = {
			isa = PBXGroup;
			children = (
				4B3D23BB1337FC5800DD29B8 /* Info.plist */,
				4B19023A1338D6A2000374C9 /* Makefile */,
				4BDF37B41338055600F9A81A /* config.h */,
				4B3D23EF1338008000DD29B8 /* mach_alias_list */,
				4BD98C011338140B0048DD5B /* objfw-defs.h */,
			);
			name = "Supporting Files";
			path = ObjFW;
			sourceTree = "<group>";
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
				4BF33B4113380CB60059CEF7 /* Supporting Files */,
				4B6EF682123535960076B512 /* objc_sync */,
				4B6EF66E1235358D0076B512 /* OFArrayTests.m */,
				4BE5F0E412DF4259005C7A0C /* OFBlockTests.m */,
				4B6EF66F1235358D0076B512 /* OFDataArrayTests.m */,
				4BE5F0E512DF4259005C7A0C /* OFDateTests.m */,
				4B6EF6701235358D0076B512 /* OFDictionaryTests.m */,
				4B6EF6711235358D0076B512 /* OFFileTests.m */,
				4B3D23701337FB7500DD29B8 /* OFHTTPRequestTests.m */,
				4B6EF6721235358D0076B512 /* OFListTests.m */,
				4B6EF6731235358D0076B512 /* OFMD5HashTests.m */,
				4B6EF6741235358D0076B512 /* OFNumberTests.m */,
				4B6EF6751235358D0076B512 /* OFObjectTests.m */,
				4B6EF6761235358D0076B512 /* OFPluginTests.m */,
				4B6EF6771235358D0076B512 /* OFSHA1HashTests.m */,







<







530
531
532
533
534
535
536

537
538
539
540
541
542
543
				4BF33B4113380CB60059CEF7 /* Supporting Files */,
				4B6EF682123535960076B512 /* objc_sync */,
				4B6EF66E1235358D0076B512 /* OFArrayTests.m */,
				4BE5F0E412DF4259005C7A0C /* OFBlockTests.m */,
				4B6EF66F1235358D0076B512 /* OFDataArrayTests.m */,
				4BE5F0E512DF4259005C7A0C /* OFDateTests.m */,
				4B6EF6701235358D0076B512 /* OFDictionaryTests.m */,

				4B3D23701337FB7500DD29B8 /* OFHTTPRequestTests.m */,
				4B6EF6721235358D0076B512 /* OFListTests.m */,
				4B6EF6731235358D0076B512 /* OFMD5HashTests.m */,
				4B6EF6741235358D0076B512 /* OFNumberTests.m */,
				4B6EF6751235358D0076B512 /* OFObjectTests.m */,
				4B6EF6761235358D0076B512 /* OFPluginTests.m */,
				4B6EF6771235358D0076B512 /* OFSHA1HashTests.m */,
579
580
581
582
583
584
585

586
587
588
589
590
591
592
			);
			name = Frameworks;
			sourceTree = "<group>";
		};
		4BF33B4113380CB60059CEF7 /* Supporting Files */ = {
			isa = PBXGroup;
			children = (

				4BF33B4213380CD40059CEF7 /* testfile.bin */,
				4BF33B4313380CD40059CEF7 /* testfile.txt */,
			);
			name = "Supporting Files";
			sourceTree = "<group>";
		};
/* End PBXGroup section */







>







579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
			);
			name = Frameworks;
			sourceTree = "<group>";
		};
		4BF33B4113380CB60059CEF7 /* Supporting Files */ = {
			isa = PBXGroup;
			children = (
				4B19023D1338D6D5000374C9 /* Makefile */,
				4BF33B4213380CD40059CEF7 /* testfile.bin */,
				4BF33B4313380CD40059CEF7 /* testfile.txt */,
			);
			name = "Supporting Files";
			sourceTree = "<group>";
		};
/* End PBXGroup section */
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
			buildActionMask = 2147483647;
			files = (
				4BF33AFC133807A20059CEF7 /* OFArrayTests.m in Sources */,
				4BF33AFD133807A20059CEF7 /* OFBlockTests.m in Sources */,
				4BF33AFE133807A20059CEF7 /* OFDataArrayTests.m in Sources */,
				4BF33AFF133807A20059CEF7 /* OFDateTests.m in Sources */,
				4BF33B00133807A20059CEF7 /* OFDictionaryTests.m in Sources */,
				4BF33B01133807A20059CEF7 /* OFFileTests.m in Sources */,
				4BF33B02133807A20059CEF7 /* OFHTTPRequestTests.m in Sources */,
				4BF33B03133807A20059CEF7 /* OFListTests.m in Sources */,
				4BF33B04133807A20059CEF7 /* OFMD5HashTests.m in Sources */,
				4BF33B05133807A20059CEF7 /* OFNumberTests.m in Sources */,
				4BF33B06133807A20059CEF7 /* OFObjectTests.m in Sources */,
				4BF33B07133807A20059CEF7 /* OFPluginTests.m in Sources */,
				4BF33B08133807A20059CEF7 /* OFSHA1HashTests.m in Sources */,







<







856
857
858
859
860
861
862

863
864
865
866
867
868
869
			buildActionMask = 2147483647;
			files = (
				4BF33AFC133807A20059CEF7 /* OFArrayTests.m in Sources */,
				4BF33AFD133807A20059CEF7 /* OFBlockTests.m in Sources */,
				4BF33AFE133807A20059CEF7 /* OFDataArrayTests.m in Sources */,
				4BF33AFF133807A20059CEF7 /* OFDateTests.m in Sources */,
				4BF33B00133807A20059CEF7 /* OFDictionaryTests.m in Sources */,

				4BF33B02133807A20059CEF7 /* OFHTTPRequestTests.m in Sources */,
				4BF33B03133807A20059CEF7 /* OFListTests.m in Sources */,
				4BF33B04133807A20059CEF7 /* OFMD5HashTests.m in Sources */,
				4BF33B05133807A20059CEF7 /* OFNumberTests.m in Sources */,
				4BF33B06133807A20059CEF7 /* OFObjectTests.m in Sources */,
				4BF33B07133807A20059CEF7 /* OFPluginTests.m in Sources */,
				4BF33B08133807A20059CEF7 /* OFSHA1HashTests.m in Sources */,

Modified src/OFFile.h from [8d2faaebb5] to [dd9704b3e3].

50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
/**
 * \param fd A file descriptor, returned from for example open().
 *	     It is not closed when the OFFile object is deallocated!
 * \return A new autoreleased OFFile
 */
+ fileWithFileDescriptor: (int)fd;

/**
 * \param path The path for which the components should be returned
 * \return The components of the path
 */
+ (OFArray*)componentsOfPath: (OFString*)path;

/**
 * \param path The path for which the last component should be returned
 * \return The last component of the path
 */
+ (OFString*)lastComponentOfPath: (OFString*)path;

/**
 * \param path The path for which the directory name should be returned
 * \return The directory name of the path
 */
+ (OFString*)directoryNameOfPath: (OFString*)path;

/**
 * \param path The path to check
 * \return A boolean whether there is a file at the specified path
 */
+ (BOOL)fileExistsAtPath: (OFString*)path;

/**







<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<







50
51
52
53
54
55
56


















57
58
59
60
61
62
63
/**
 * \param fd A file descriptor, returned from for example open().
 *	     It is not closed when the OFFile object is deallocated!
 * \return A new autoreleased OFFile
 */
+ fileWithFileDescriptor: (int)fd;



















/**
 * \param path The path to check
 * \return A boolean whether there is a file at the specified path
 */
+ (BOOL)fileExistsAtPath: (OFString*)path;

/**

Modified src/OFFile.m from [23bde42f6d] to [3a17566619].

111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
	OFAutoreleasePool *pool = [[OFAutoreleasePool alloc] init];
	OFDate *date;
	OFString *date_str, *me, *msg;
	va_list args;

	date = [OFDate date];
	date_str = [date localDateStringWithFormat: @"%Y-%m-%d %H:%M:%S"];
	me = [OFFile lastComponentOfPath: [OFApplication programName]];

	va_start(args, fmt);
	msg = [[[OFString alloc] initWithFormat: fmt
				      arguments: args] autorelease];
	va_end(args);

	[of_stderr writeFormat: @"[%@.%03d %@(%d)] %@\n", date_str,
				[date microsecond] / 1000, me, getpid(), msg];

	[pool release];
}

@interface OFFileSingleton: OFFile
@end

@implementation OFFile
+ (void)load
{
	if (self != [OFFile class])
		return;

	of_stdin = [[OFFileSingleton alloc] initWithFileDescriptor: 0];
	of_stdout = [[OFFileSingleton alloc] initWithFileDescriptor: 1];
	of_stderr = [[OFFileSingleton alloc] initWithFileDescriptor: 2];
}

#if defined(OF_THREADS) && !defined(_WIN32)
+ (void)initialize







|


















<
<
<







111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136



137
138
139
140
141
142
143
	OFAutoreleasePool *pool = [[OFAutoreleasePool alloc] init];
	OFDate *date;
	OFString *date_str, *me, *msg;
	va_list args;

	date = [OFDate date];
	date_str = [date localDateStringWithFormat: @"%Y-%m-%d %H:%M:%S"];
	me = [[OFApplication programName] lastPathComponent];

	va_start(args, fmt);
	msg = [[[OFString alloc] initWithFormat: fmt
				      arguments: args] autorelease];
	va_end(args);

	[of_stderr writeFormat: @"[%@.%03d %@(%d)] %@\n", date_str,
				[date microsecond] / 1000, me, getpid(), msg];

	[pool release];
}

@interface OFFileSingleton: OFFile
@end

@implementation OFFile
+ (void)load
{



	of_stdin = [[OFFileSingleton alloc] initWithFileDescriptor: 0];
	of_stdout = [[OFFileSingleton alloc] initWithFileDescriptor: 1];
	of_stderr = [[OFFileSingleton alloc] initWithFileDescriptor: 2];
}

#if defined(OF_THREADS) && !defined(_WIN32)
+ (void)initialize
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
}

+ fileWithFileDescriptor: (int)fd_
{
	return [[[self alloc] initWithFileDescriptor: fd_] autorelease];
}

+ (OFArray*)componentsOfPath: (OFString*)path
{
	OFMutableArray *ret;
	OFAutoreleasePool *pool;
	const char *path_c = [path cString];
	size_t path_len = [path cStringLength];
	size_t i, last = 0;

	ret = [OFMutableArray array];

	if (path_len == 0)
		return ret;

	pool = [[OFAutoreleasePool alloc] init];

#ifndef _WIN32
	if (path_c[path_len - 1] == OF_PATH_DELIM)
#else
	if (path_c[path_len - 1] == '/' || path_c[path_len - 1] == '\\')
#endif
		path_len--;

	for (i = 0; i < path_len; i++) {
#ifndef _WIN32
		if (path_c[i] == OF_PATH_DELIM) {
#else
		if (path_c[i] == '/' || path_c[i] == '\\') {
#endif
			[ret addObject:
			    [OFString stringWithCString: path_c + last
						 length: i - last]];
			last = i + 1;
		}
	}

	[ret addObject: [OFString stringWithCString: path_c + last
					     length: i - last]];

	[pool release];

	/*
	 * Class swizzle the array to be immutable. We declared the return type
	 * to be OFArray*, so it can't be modified anyway. But not swizzling it
	 * would create a real copy each time -[copy] is called.
	 */
	ret->isa = [OFArray class];
	return ret;
}

+ (OFString*)lastComponentOfPath: (OFString*)path
{
	const char *path_c = [path cString];
	size_t path_len = [path cStringLength];
	ssize_t i;

	if (path_len == 0)
		return @"";

#ifndef _WIN32
	if (path_c[path_len - 1] == OF_PATH_DELIM)
#else
	if (path_c[path_len - 1] == '/' || path_c[path_len - 1] == '\\')
#endif
		path_len--;

	for (i = path_len - 1; i >= 0; i--) {
#ifndef _WIN32
		if (path_c[i] == OF_PATH_DELIM) {
#else
		if (path_c[i] == '/' || path_c[i] == '\\') {
#endif
			i++;
			break;
		}
	}

	/*
	 * Only one component, but the trailing delimiter might have been
	 * removed, so return a new string anyway.
	 */
	if (i < 0)
		i = 0;

	return [OFString stringWithCString: path_c + i
				    length: path_len - i];
}

+ (OFString*)directoryNameOfPath: (OFString*)path
{
	const char *path_c = [path cString];
	size_t path_len = [path cStringLength];
	size_t i;

	if (path_len == 0)
		return @"";

#ifndef _WIN32
	if (path_c[path_len - 1] == OF_PATH_DELIM)
#else
	if (path_c[path_len - 1] == '/' || path_c[path_len - 1] == '\\')
#endif
		path_len--;

	if (path_len == 0)
		return [OFString stringWithCString: path_c
					    length: 1];

	for (i = path_len - 1; i >= 1; i--)
#ifndef _WIN32
		if (path_c[i] == OF_PATH_DELIM)
#else
		if (path_c[i] == '/' || path_c[i] == '\\')
#endif
			return [OFString stringWithCString: path_c
						    length: i];

#ifndef _WIN32
	if (path_c[0] == OF_PATH_DELIM)
#else
	if (path_c[i] == '/' || path_c[i] == '\\')
#endif
		return [OFString stringWithCString: path_c
					    length: 1];

	return @".";
}

+ (BOOL)fileExistsAtPath: (OFString*)path
{
	struct stat s;

	if (stat([path cString], &s) == -1)
		return NO;








<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<







155
156
157
158
159
160
161































































































































162
163
164
165
166
167
168
}

+ fileWithFileDescriptor: (int)fd_
{
	return [[[self alloc] initWithFileDescriptor: fd_] autorelease];
}
































































































































+ (BOOL)fileExistsAtPath: (OFString*)path
{
	struct stat s;

	if (stat([path cString], &s) == -1)
		return NO;

516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
	OFAutoreleasePool *pool = [[OFAutoreleasePool alloc] init];
	BOOL override;
	OFFile *src;
	OFFile *dest;
	char buf[4096];

	if ([self directoryExistsAtPath: to]) {
		OFString *filename = [self lastComponentOfPath: from];
		to = [OFString stringWithPath: to, filename, nil];
	}

	override = [self fileExistsAtPath: to];

	src = nil;
	dest = nil;







|







386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
	OFAutoreleasePool *pool = [[OFAutoreleasePool alloc] init];
	BOOL override;
	OFFile *src;
	OFFile *dest;
	char buf[4096];

	if ([self directoryExistsAtPath: to]) {
		OFString *filename = [from lastPathComponent];
		to = [OFString stringWithPath: to, filename, nil];
	}

	override = [self fileExistsAtPath: to];

	src = nil;
	dest = nil;
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
	[pool release];
}

+ (void)renameFileAtPath: (OFString*)from
		  toPath: (OFString*)to
{
	if ([self directoryExistsAtPath: to]) {
		OFString *filename = [self lastComponentOfPath: from];
		to = [OFString stringWithPath: to, filename, nil];
	}

#ifndef _WIN32
	if (rename([from cString], [to cString]))
#else
	if (!MoveFile([from cString], [to cString]))







|







428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
	[pool release];
}

+ (void)renameFileAtPath: (OFString*)from
		  toPath: (OFString*)to
{
	if ([self directoryExistsAtPath: to]) {
		OFString *filename = [from lastPathComponent];
		to = [OFString stringWithPath: to, filename, nil];
	}

#ifndef _WIN32
	if (rename([from cString], [to cString]))
#else
	if (!MoveFile([from cString], [to cString]))
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
}

#ifndef _WIN32
+ (void)linkFileAtPath: (OFString*)src
		toPath: (OFString*)dest
{
	if ([self directoryExistsAtPath: dest]) {
		OFString *filename = [self lastComponentOfPath: src];
		dest = [OFString stringWithPath: dest, filename, nil];
	}

	if (link([src cString], [dest cString]) != 0)
		@throw [OFLinkFailedException newWithClass: self
						sourcePath: src
					   destinationPath: dest];
}
#endif

#if !defined(_WIN32) && !defined(_PSP)
+ (void)symlinkFileAtPath: (OFString*)src
		   toPath: (OFString*)dest
{
	if ([self directoryExistsAtPath: dest]) {
		OFString *filename = [self lastComponentOfPath: src];
		dest = [OFString stringWithPath: dest, filename, nil];
	}

	if (symlink([src cString], [dest cString]) != 0)
		@throw [OFSymlinkFailedException newWithClass: self
						   sourcePath: src
					      destinationPath: dest];







|















|







465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
}

#ifndef _WIN32
+ (void)linkFileAtPath: (OFString*)src
		toPath: (OFString*)dest
{
	if ([self directoryExistsAtPath: dest]) {
		OFString *filename = [src lastPathComponent];
		dest = [OFString stringWithPath: dest, filename, nil];
	}

	if (link([src cString], [dest cString]) != 0)
		@throw [OFLinkFailedException newWithClass: self
						sourcePath: src
					   destinationPath: dest];
}
#endif

#if !defined(_WIN32) && !defined(_PSP)
+ (void)symlinkFileAtPath: (OFString*)src
		   toPath: (OFString*)dest
{
	if ([self directoryExistsAtPath: dest]) {
		OFString *filename = [src lastPathComponent];
		dest = [OFString stringWithPath: dest, filename, nil];
	}

	if (symlink([src cString], [dest cString]) != 0)
		@throw [OFSymlinkFailedException newWithClass: self
						   sourcePath: src
					      destinationPath: dest];

Modified src/OFString.h from [9b66ad1a81] to [7f5553838b].

395
396
397
398
399
400
401















402
403
404
405
406
407
408
 * Splits an OFString into an OFArray of OFStrings.
 *
 * \param delimiter The delimiter for splitting
 * \return An autoreleased OFArray with the splitted string
 */
- (OFArray*)componentsSeparatedByString: (OFString*)delimiter;
















/**
 * Returns the decimal value of the string as an intmax_t or throws an
 * OFInvalidEncoding exception if the string contains any non-number characters.
 *
 * \return An intmax_t with the value of the string
 */
- (intmax_t)decimalValue;







>
>
>
>
>
>
>
>
>
>
>
>
>
>
>







395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
 * Splits an OFString into an OFArray of OFStrings.
 *
 * \param delimiter The delimiter for splitting
 * \return An autoreleased OFArray with the splitted string
 */
- (OFArray*)componentsSeparatedByString: (OFString*)delimiter;

/**
 * \return The components of the path
 */
- (OFArray*)pathComponents;

/**
 * \return The last component of the path
 */
- (OFString*)lastPathComponent;

/**
 * \return The directory name of the path
 */
- (OFString*)stringByDeletingLastPathComponent;

/**
 * Returns the decimal value of the string as an intmax_t or throws an
 * OFInvalidEncoding exception if the string contains any non-number characters.
 *
 * \return An intmax_t with the value of the string
 */
- (intmax_t)decimalValue;

Modified src/OFString.m from [117e48e1f5] to [e113731f30].

1066
1067
1068
1069
1070
1071
1072


























































































































1073
1074
1075
1076
1077
1078
1079
	 * Class swizzle the array to be immutable. We declared the return type
	 * to be OFArray*, so it can't be modified anyway. But not swizzling it
	 * would create a real copy each time -[copy] is called.
	 */
	array->isa = [OFArray class];
	return array;
}



























































































































- (intmax_t)decimalValue
{
	int i = 0;
	intmax_t num = 0;

	if (string[0] == '-' || string[0] == '+')







>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>







1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
	 * Class swizzle the array to be immutable. We declared the return type
	 * to be OFArray*, so it can't be modified anyway. But not swizzling it
	 * would create a real copy each time -[copy] is called.
	 */
	array->isa = [OFArray class];
	return array;
}

- (OFArray*)pathComponents
{
	OFMutableArray *ret;
	OFAutoreleasePool *pool;
	size_t i, last = 0, path_len = length;

	ret = [OFMutableArray array];

	if (path_len == 0)
		return ret;

	pool = [[OFAutoreleasePool alloc] init];

#ifndef _WIN32
	if (string[path_len - 1] == OF_PATH_DELIM)
#else
	if (string[path_len - 1] == '/' || string[path_len - 1] == '\\')
#endif
		path_len--;

	for (i = 0; i < path_len; i++) {
#ifndef _WIN32
		if (string[i] == OF_PATH_DELIM) {
#else
		if (string[i] == '/' || string[i] == '\\') {
#endif
			[ret addObject:
			    [OFString stringWithCString: string + last
						 length: i - last]];
			last = i + 1;
		}
	}

	[ret addObject: [OFString stringWithCString: string + last
					     length: i - last]];

	[pool release];

	/*
	 * Class swizzle the array to be immutable. We declared the return type
	 * to be OFArray*, so it can't be modified anyway. But not swizzling it
	 * would create a real copy each time -[copy] is called.
	 */
	ret->isa = [OFArray class];
	return ret;
}

- (OFString*)lastPathComponent
{
	size_t path_len = length;
	ssize_t i;

	if (path_len == 0)
		return @"";

#ifndef _WIN32
	if (string[path_len - 1] == OF_PATH_DELIM)
#else
	if (string[path_len - 1] == '/' || string[path_len - 1] == '\\')
#endif
		path_len--;

	for (i = path_len - 1; i >= 0; i--) {
#ifndef _WIN32
		if (string[i] == OF_PATH_DELIM) {
#else
		if (string[i] == '/' || string[i] == '\\') {
#endif
			i++;
			break;
		}
	}

	/*
	 * Only one component, but the trailing delimiter might have been
	 * removed, so return a new string anyway.
	 */
	if (i < 0)
		i = 0;

	return [OFString stringWithCString: string + i
				    length: path_len - i];
}

- (OFString*)stringByDeletingLastPathComponent;
{
	size_t i, path_len = length;

	if (path_len == 0)
		return @"";

#ifndef _WIN32
	if (string[path_len - 1] == OF_PATH_DELIM)
#else
	if (string[path_len - 1] == '/' || string[path_len - 1] == '\\')
#endif
		path_len--;

	if (path_len == 0)
		return [OFString stringWithCString: string
					    length: 1];

	for (i = path_len - 1; i >= 1; i--)
#ifndef _WIN32
		if (string[i] == OF_PATH_DELIM)
#else
		if (string[i] == '/' || string[i] == '\\')
#endif
			return [OFString stringWithCString: string
						    length: i];

#ifndef _WIN32
	if (string[0] == OF_PATH_DELIM)
#else
	if (path_c[i] == '/' || path_c[i] == '\\')
#endif
		return [OFString stringWithCString: string
					    length: 1];

	return @".";
}

- (intmax_t)decimalValue
{
	int i = 0;
	intmax_t num = 0;

	if (string[0] == '-' || string[0] == '+')

Modified tests/Makefile from [4715af7315] to [3f27a86069].

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
include ../extra.mk

SUBDIRS = ${TESTPLUGIN}

PROG_NOINST = tests${PROG_SUFFIX}
SRCS = OFArrayTests.m			\
       ${OFBLOCKTESTS_M}		\
       OFDataArrayTests.m		\
       OFDateTests.m			\
       OFDictionaryTests.m		\
       OFFileTests.m			\
       ${OFHTTPREQUESTTESTS_M}		\
       OFListTests.m			\
       OFMD5HashTests.m			\
       OFNumberTests.m			\
       OFObjectTests.m			\
       ${OFPLUGINTESTS_M}		\
       OFSHA1HashTests.m		\










<







1
2
3
4
5
6
7
8
9
10

11
12
13
14
15
16
17
include ../extra.mk

SUBDIRS = ${TESTPLUGIN}

PROG_NOINST = tests${PROG_SUFFIX}
SRCS = OFArrayTests.m			\
       ${OFBLOCKTESTS_M}		\
       OFDataArrayTests.m		\
       OFDateTests.m			\
       OFDictionaryTests.m		\

       ${OFHTTPREQUESTTESTS_M}		\
       OFListTests.m			\
       OFMD5HashTests.m			\
       OFNumberTests.m			\
       OFObjectTests.m			\
       ${OFPLUGINTESTS_M}		\
       OFSHA1HashTests.m		\

Modified tests/OFStringTests.m from [77a4fe93c0] to [bb6dd3680d].

168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
	    [(s[0] = [OFMutableString stringWithFormat: @"%@:%d", @"test", 123])
	    isEqual: @"test:123"])

	TEST(@"-[appendFormat:]",
	    R(([s[0] appendFormat: @"%02X", 15])) &&
	    [s[0] isEqual: @"test:1230F"])

	TEST(@"+[stringWithPath:]",
	    (s[0] = [OFString stringWithPath: @"foo", @"bar", @"baz", nil]) &&
#ifndef _WIN32
	    [s[0] isEqual: @"foo/bar/baz"] &&
#else
	    [s[0] isEqual: @"foo\\bar\\baz"] &&
#endif
	    (s[0] = [OFString stringWithPath: @"foo", nil]) &&
	    [s[0] isEqual: @"foo"])

	TEST(@"-[indexOfFirstOccurrenceOfString:]",
	    [@"π„žΓΆΓΆ" indexOfFirstOccurrenceOfString: @"ΓΆΓΆ"] == 1 &&
	    [@"π„žΓΆΓΆ" indexOfFirstOccurrenceOfString: @"ΓΆ"] == 1 &&
	    [@"π„žΓΆΓΆ" indexOfFirstOccurrenceOfString: @"π„ž"] == 0 &&
	    [@"π„žΓΆΓΆ" indexOfFirstOccurrenceOfString: @"x"] == SIZE_MAX)

	TEST(@"-[indexOfLastOccurrenceOfString:]",







<
<
<
<
<
<
<
<
<
<







168
169
170
171
172
173
174










175
176
177
178
179
180
181
	    [(s[0] = [OFMutableString stringWithFormat: @"%@:%d", @"test", 123])
	    isEqual: @"test:123"])

	TEST(@"-[appendFormat:]",
	    R(([s[0] appendFormat: @"%02X", 15])) &&
	    [s[0] isEqual: @"test:1230F"])











	TEST(@"-[indexOfFirstOccurrenceOfString:]",
	    [@"π„žΓΆΓΆ" indexOfFirstOccurrenceOfString: @"ΓΆΓΆ"] == 1 &&
	    [@"π„žΓΆΓΆ" indexOfFirstOccurrenceOfString: @"ΓΆ"] == 1 &&
	    [@"π„žΓΆΓΆ" indexOfFirstOccurrenceOfString: @"π„ž"] == 0 &&
	    [@"π„žΓΆΓΆ" indexOfFirstOccurrenceOfString: @"x"] == SIZE_MAX)

	TEST(@"-[indexOfLastOccurrenceOfString:]",
229
230
231
232
233
234
235






















































236
237
238
239
240
241
242
	    [[a objectAtIndex: i++] isEqual: @"foo"] &&
	    [[a objectAtIndex: i++] isEqual: @"bar"] &&
	    [[a objectAtIndex: i++] isEqual: @""] &&
	    [[a objectAtIndex: i++] isEqual: @"baz"] &&
	    [[a objectAtIndex: i++] isEqual: @""] &&
	    [[a objectAtIndex: i++] isEqual: @""])























































	TEST(@"-[decimalValue]",
	    [@"1234" decimalValue] == 1234 &&
	    [@"+123" decimalValue] == 123 &&
	    [@"-500" decimalValue] == -500 &&
	    [@"" decimalValue] == 0)

	TEST(@"-[hexadecimalValue]",







>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>







219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
	    [[a objectAtIndex: i++] isEqual: @"foo"] &&
	    [[a objectAtIndex: i++] isEqual: @"bar"] &&
	    [[a objectAtIndex: i++] isEqual: @""] &&
	    [[a objectAtIndex: i++] isEqual: @"baz"] &&
	    [[a objectAtIndex: i++] isEqual: @""] &&
	    [[a objectAtIndex: i++] isEqual: @""])

	TEST(@"+[stringWithPath:]",
	    (s[0] = [OFString stringWithPath: @"foo", @"bar", @"baz", nil]) &&
#ifndef _WIN32
	    [s[0] isEqual: @"foo/bar/baz"] &&
#else
	    [s[0] isEqual: @"foo\\bar\\baz"] &&
#endif
	    (s[0] = [OFString stringWithPath: @"foo", nil]) &&
	    [s[0] isEqual: @"foo"])

	TEST(@"-[pathComponents]",
	    /* /tmp */
	    (a = [@"/tmp" pathComponents]) && [a count] == 2 &&
	    [[a objectAtIndex: 0] isEqual: @""] &&
	    [[a objectAtIndex: 1] isEqual: @"tmp"] &&
	    /* /tmp/ */
	    (a = [@"/tmp/" pathComponents]) && [a count] == 2 &&
	    [[a objectAtIndex: 0] isEqual: @""] &&
	    [[a objectAtIndex: 1] isEqual: @"tmp"] &&
	    /* / */
	    (a = [@"/" pathComponents]) && [a count] == 1 &&
	    [[a objectAtIndex: 0] isEqual: @""] &&
	    /* foo/bar */
	    (a = [@"foo/bar" pathComponents]) && [a count] == 2 &&
	    [[a objectAtIndex: 0] isEqual: @"foo"] &&
	    [[a objectAtIndex: 1] isEqual: @"bar"] &&
	    /* foo/bar/baz/ */
	    (a = [@"foo/bar/baz" pathComponents]) && [a count] == 3 &&
	    [[a objectAtIndex: 0] isEqual: @"foo"] &&
	    [[a objectAtIndex: 1] isEqual: @"bar"] &&
	    [[a objectAtIndex: 2] isEqual: @"baz"] &&
	    /* foo// */
	    (a = [@"foo//" pathComponents]) && [a count] == 2 &&
	    [[a objectAtIndex: 0] isEqual: @"foo"] &&
	    [[a objectAtIndex: 1] isEqual: @""] &&
	    [[@"" pathComponents] count] == 0)

	TEST(@"-[lastPathComponent]",
	    [[@"/tmp" lastPathComponent] isEqual: @"tmp"] &&
	    [[@"/tmp/" lastPathComponent] isEqual: @"tmp"] &&
	    [[@"/" lastPathComponent] isEqual: @""] &&
	    [[@"foo" lastPathComponent] isEqual: @"foo"] &&
	    [[@"foo/bar" lastPathComponent] isEqual: @"bar"] &&
	    [[@"foo/bar/baz/" lastPathComponent] isEqual: @"baz"])

	TEST(@"-[stringByDeletingLastPathComponent]",
	    [[@"/tmp" stringByDeletingLastPathComponent] isEqual: @"/"] &&
	    [[@"/tmp/" stringByDeletingLastPathComponent] isEqual: @"/"] &&
	    [[@"/tmp/foo/" stringByDeletingLastPathComponent]
	    isEqual: @"/tmp"] &&
	    [[@"foo/bar" stringByDeletingLastPathComponent] isEqual: @"foo"] &&
	    [[@"/" stringByDeletingLastPathComponent] isEqual: @"/"] &&
	    [[@"foo" stringByDeletingLastPathComponent] isEqual: @"."])

	TEST(@"-[decimalValue]",
	    [@"1234" decimalValue] == 1234 &&
	    [@"+123" decimalValue] == 123 &&
	    [@"-500" decimalValue] == -500 &&
	    [@"" decimalValue] == 0)

	TEST(@"-[hexadecimalValue]",

Modified tests/TestsAppDelegate.h from [fc5dd537d5] to [04f3a2b803].

89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
- (void)dateTests;
@end

@interface TestsAppDelegate (OFDictionaryTests)
- (void)dictionaryTests;
@end

@interface TestsAppDelegate (OFFileTests)
- (void)fileTests;
@end

@interface TestsAppDelegate (OFHTTPRequestTests)
- (void)HTTPRequestTests;
@end

@interface TestsAppDelegate (OFListTests)
- (void)listTests;
@end







<
<
<
<







89
90
91
92
93
94
95




96
97
98
99
100
101
102
- (void)dateTests;
@end

@interface TestsAppDelegate (OFDictionaryTests)
- (void)dictionaryTests;
@end





@interface TestsAppDelegate (OFHTTPRequestTests)
- (void)HTTPRequestTests;
@end

@interface TestsAppDelegate (OFListTests)
- (void)listTests;
@end

Modified tests/TestsAppDelegate.m from [43bd7328ba] to [28709e403c].

117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
#endif

	[self objectTests];
#ifdef OF_HAVE_BLOCKS
	[self blockTests];
#endif
	[self stringTests];
	[self fileTests];
	[self MD5HashTests];
	[self SHA1HashTests];
	[self dataArrayTests];
	[self arrayTests];
	[self dictionaryTests];
	[self listTests];
	[self dateTests];







<







117
118
119
120
121
122
123

124
125
126
127
128
129
130
#endif

	[self objectTests];
#ifdef OF_HAVE_BLOCKS
	[self blockTests];
#endif
	[self stringTests];

	[self MD5HashTests];
	[self SHA1HashTests];
	[self dataArrayTests];
	[self arrayTests];
	[self dictionaryTests];
	[self listTests];
	[self dateTests];