ObjFW  Check-in [1d7a1cbca0]

Overview
Comment:Move private methods into private headers.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: 1d7a1cbca0696fee838af809449bc66abfe8c0911c05fcadc3b20fd12ce69e76
User & Date: js on 2013-08-15 19:00:42
Other Links: manifest | tags
Context
2013-08-15
20:23
OFZIPArchiveEntry: Export the extra field. check-in: bf0db50a84 user: js tags: trunk
19:00
Move private methods into private headers. check-in: 1d7a1cbca0 user: js tags: trunk
18:44
Add OF_HAVE_CLASS_EXTENSIONS. check-in: a5bfaa315b user: js tags: trunk
Changes

Modified ObjFW.xcodeproj/project.pbxproj from [5d667115f4] to [a70a46e1af].

277
278
279
280
281
282
283







284
285
286
287
288
289
290
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297







+
+
+
+
+
+
+







		4B674400163C395900EB1E59 /* OFCondition.h in Headers */ = {isa = PBXBuildFile; fileRef = 4B6743F7163C395900EB1E59 /* OFCondition.h */; settings = {ATTRIBUTES = (Public, ); }; };
		4B674401163C395900EB1E59 /* OFCondition.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B6743F8163C395900EB1E59 /* OFCondition.m */; };
		4B674402163C395900EB1E59 /* OFLocking.h in Headers */ = {isa = PBXBuildFile; fileRef = 4B6743F9163C395900EB1E59 /* OFLocking.h */; settings = {ATTRIBUTES = (Public, ); }; };
		4B674403163C395900EB1E59 /* OFMutex.h in Headers */ = {isa = PBXBuildFile; fileRef = 4B6743FA163C395900EB1E59 /* OFMutex.h */; settings = {ATTRIBUTES = (Public, ); }; };
		4B674404163C395900EB1E59 /* OFMutex.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B6743FB163C395900EB1E59 /* OFMutex.m */; };
		4B674405163C395900EB1E59 /* OFRecursiveMutex.h in Headers */ = {isa = PBXBuildFile; fileRef = 4B6743FC163C395900EB1E59 /* OFRecursiveMutex.h */; settings = {ATTRIBUTES = (Public, ); }; };
		4B674406163C395900EB1E59 /* OFRecursiveMutex.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B6743FD163C395900EB1E59 /* OFRecursiveMutex.m */; };
		4B6C8AD817BD5C2E00B194F2 /* OFRunLoop+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = 4B6C8AD117BD5C2E00B194F2 /* OFRunLoop+Private.h */; };
		4B6C8AD917BD5C2E00B194F2 /* OFStream+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = 4B6C8AD217BD5C2E00B194F2 /* OFStream+Private.h */; };
		4B6C8ADA17BD5C2E00B194F2 /* OFStreamObserver+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = 4B6C8AD317BD5C2E00B194F2 /* OFStreamObserver+Private.h */; };
		4B6C8ADB17BD5C2E00B194F2 /* OFString_UTF8+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = 4B6C8AD417BD5C2E00B194F2 /* OFString_UTF8+Private.h */; };
		4B6C8ADC17BD5C2E00B194F2 /* OFThread+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = 4B6C8AD517BD5C2E00B194F2 /* OFThread+Private.h */; };
		4B6C8ADD17BD5C2E00B194F2 /* OFTimer+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = 4B6C8AD617BD5C2E00B194F2 /* OFTimer+Private.h */; };
		4B6C8ADE17BD5C2E00B194F2 /* OFZIPArchiveEntry+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = 4B6C8AD717BD5C2E00B194F2 /* OFZIPArchiveEntry+Private.h */; };
		4B7161AD17A6FC7600B74970 /* OFHTTPResponse.h in Headers */ = {isa = PBXBuildFile; fileRef = 4B7161AB17A6FC7600B74970 /* OFHTTPResponse.h */; settings = {ATTRIBUTES = (Public, ); }; };
		4B7161AE17A6FC7600B74970 /* OFHTTPResponse.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B7161AC17A6FC7600B74970 /* OFHTTPResponse.m */; };
		4B745BA5168B25E600A6C20E /* OFSystemInfo.h in Headers */ = {isa = PBXBuildFile; fileRef = 4B745BA3168B25E600A6C20E /* OFSystemInfo.h */; settings = {ATTRIBUTES = (Public, ); }; };
		4B745BA6168B25E600A6C20E /* OFSystemInfo.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B745BA4168B25E600A6C20E /* OFSystemInfo.m */; };
		4B7FF3B4133CED6200000324 /* OFConditionStillWaitingException.h in Headers */ = {isa = PBXBuildFile; fileRef = 4B7FF3B2133CED6100000324 /* OFConditionStillWaitingException.h */; settings = {ATTRIBUTES = (Public, ); }; };
		4B7FF3B5133CED6200000324 /* OFConditionStillWaitingException.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B7FF3B3133CED6100000324 /* OFConditionStillWaitingException.m */; };
		4B837D7916829C5F007A3E83 /* block.h in Headers */ = {isa = PBXBuildFile; fileRef = 4B837D7716829C5F007A3E83 /* block.h */; settings = {ATTRIBUTES = (Public, ); }; };
674
675
676
677
678
679
680







681
682
683
684
685
686
687
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701







+
+
+
+
+
+
+







		4B67998A1099E7C50041064A /* OFXMLParser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFXMLParser.m; path = src/OFXMLParser.m; sourceTree = "<group>"; };
		4B67998B1099E7C50041064A /* threading.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = threading.h; path = src/threading.h; sourceTree = "<group>"; };
		4B67998C1099E7C50041064A /* unicode.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = unicode.h; path = src/unicode.h; sourceTree = "<group>"; };
		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>"; };
		4B6C8AD117BD5C2E00B194F2 /* OFRunLoop+Private.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = "OFRunLoop+Private.h"; path = "src/OFRunLoop+Private.h"; sourceTree = "<group>"; };
		4B6C8AD217BD5C2E00B194F2 /* OFStream+Private.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = "OFStream+Private.h"; path = "src/OFStream+Private.h"; sourceTree = "<group>"; };
		4B6C8AD317BD5C2E00B194F2 /* OFStreamObserver+Private.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = "OFStreamObserver+Private.h"; path = "src/OFStreamObserver+Private.h"; sourceTree = "<group>"; };
		4B6C8AD417BD5C2E00B194F2 /* OFString_UTF8+Private.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = "OFString_UTF8+Private.h"; path = "src/OFString_UTF8+Private.h"; sourceTree = "<group>"; };
		4B6C8AD517BD5C2E00B194F2 /* OFThread+Private.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = "OFThread+Private.h"; path = "src/OFThread+Private.h"; sourceTree = "<group>"; };
		4B6C8AD617BD5C2E00B194F2 /* OFTimer+Private.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = "OFTimer+Private.h"; path = "src/OFTimer+Private.h"; sourceTree = "<group>"; };
		4B6C8AD717BD5C2E00B194F2 /* OFZIPArchiveEntry+Private.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = "OFZIPArchiveEntry+Private.h"; path = "src/OFZIPArchiveEntry+Private.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; };
1178
1179
1180
1181
1182
1183
1184

1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199

1200
1201

1202
1203
1204
1205
1206
1207
1208
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225







+















+


+







				4B67997A1099E7C50041064A /* OFPlugin.m */,
				4BB524BF143D1E4E0085FBCC /* OFProcess.h */,
				4BB524C0143D1E4E0085FBCC /* OFProcess.m */,
				4B6743FC163C395900EB1E59 /* OFRecursiveMutex.h */,
				4B6743FD163C395900EB1E59 /* OFRecursiveMutex.m */,
				4B325ED91605F3A0007836CA /* OFRunLoop.h */,
				4B325EDA1605F3A0007836CA /* OFRunLoop.m */,
				4B6C8AD117BD5C2E00B194F2 /* OFRunLoop+Private.h */,
				4B981CDE116F71DD00294DB7 /* OFSeekableStream.h */,
				4B981CDF116F71DD00294DB7 /* OFSeekableStream.m */,
				4B989C2E13771A3700109A30 /* OFSerialization.h */,
				4B39844013D3A24600E6F825 /* OFSet.h */,
				4B39844113D3A24600E6F825 /* OFSet.m */,
				4BA85BC8140ECCE800E91D51 /* OFSet_hashtable.h */,
				4BA85BC9140ECCE800E91D51 /* OFSet_hashtable.m */,
				4BF1BCC411C9663F0025511F /* OFSHA1Hash.h */,
				4BF1BCC511C9663F0025511F /* OFSHA1Hash.m */,
				4B141BA215FCDF74000C21A8 /* OFSortedList.h */,
				4B141BA315FCDF74000C21A8 /* OFSortedList.m */,
				4B0256E2172B60400062B5F1 /* OFStdIOStream.h */,
				4B0256E3172B60400062B5F1 /* OFStdIOStream.m */,
				4B67997D1099E7C50041064A /* OFStream.h */,
				4B67997E1099E7C50041064A /* OFStream.m */,
				4B6C8AD217BD5C2E00B194F2 /* OFStream+Private.h */,
				4BAF5F47123460C900F4E111 /* OFStreamObserver.h */,
				4BAF5F48123460C900F4E111 /* OFStreamObserver.m */,
				4B6C8AD317BD5C2E00B194F2 /* OFStreamObserver+Private.h */,
				4B83F0F2142FDEFD00E4A821 /* OFStreamObserver_kqueue.h */,
				4B83F0F3142FDEFD00E4A821 /* OFStreamObserver_kqueue.m */,
				4B64D6EB1425381E007BDFB1 /* OFStreamObserver_poll.h */,
				4B64D6EC1425381E007BDFB1 /* OFStreamObserver_poll.m */,
				4B64D6ED1425381E007BDFB1 /* OFStreamObserver_select.h */,
				4B64D6EE1425381E007BDFB1 /* OFStreamObserver_select.m */,
				4BAF5F49123460C900F4E111 /* OFStreamSocket.h */,
1219
1220
1221
1222
1223
1224
1225

1226
1227
1228
1229
1230
1231
1232
1233

1234
1235
1236
1237

1238
1239
1240
1241
1242
1243
1244
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264







+








+




+







				4BF1BCC911C9663F0025511F /* OFString+URLEncoding.m */,
				4BF1BCCA11C9663F0025511F /* OFString+XMLEscaping.h */,
				4BF1BCCB11C9663F0025511F /* OFString+XMLEscaping.m */,
				4BF1BCCC11C9663F0025511F /* OFString+XMLUnescaping.h */,
				4BF1BCCD11C9663F0025511F /* OFString+XMLUnescaping.m */,
				4B552550147AA5DB0003BF47 /* OFString_UTF8.h */,
				4B552551147AA5DB0003BF47 /* OFString_UTF8.m */,
				4B6C8AD417BD5C2E00B194F2 /* OFString_UTF8+Private.h */,
				4B745BA3168B25E600A6C20E /* OFSystemInfo.h */,
				4B745BA4168B25E600A6C20E /* OFSystemInfo.m */,
				4B6799811099E7C50041064A /* OFTCPSocket.h */,
				4B6799821099E7C50041064A /* OFTCPSocket.m */,
				4BD653C3143B8489006182F0 /* OFTCPSocket+SOCKS5.h */,
				4BD653C4143B8489006182F0 /* OFTCPSocket+SOCKS5.m */,
				4B6799831099E7C50041064A /* OFThread.h */,
				4B6799841099E7C50041064A /* OFThread.m */,
				4B6C8AD517BD5C2E00B194F2 /* OFThread+Private.h */,
				4B9361A61511000C00DCD16B /* OFThreadPool.h */,
				4B9361A71511000C00DCD16B /* OFThreadPool.m */,
				4B325EDB1605F3A0007836CA /* OFTimer.h */,
				4B325EDC1605F3A0007836CA /* OFTimer.m */,
				4B6C8AD617BD5C2E00B194F2 /* OFTimer+Private.h */,
				4BA02BA015041F5900002F84 /* OFTLSSocket.h */,
				4B4A61F212DF5EA20048F3F2 /* OFURL.h */,
				4B4A61F312DF5EA20048F3F2 /* OFURL.m */,
				4BF1BCCE11C9663F0025511F /* OFXMLAttribute.h */,
				4BF1BCCF11C9663F0025511F /* OFXMLAttribute.m */,
				4B49EA67143B3A090005BBC6 /* OFXMLCDATA.h */,
				4B49EA68143B3A090005BBC6 /* OFXMLCDATA.m */,
1258
1259
1260
1261
1262
1263
1264

1265
1266
1267
1268
1269
1270
1271
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292







+







				4B67998A1099E7C50041064A /* OFXMLParser.m */,
				4B48B95214DC23B100546D39 /* OFXMLProcessingInstructions.h */,
				4B48B95314DC23B100546D39 /* OFXMLProcessingInstructions.m */,
				4BE52D1F17B990B4005958D1 /* OFZIPArchive.h */,
				4BE52D2017B990B4005958D1 /* OFZIPArchive.m */,
				4B8B025717BBA7C7009ED983 /* OFZIPArchiveEntry.h */,
				4B8B025817BBA7C7009ED983 /* OFZIPArchiveEntry.m */,
				4B6C8AD717BD5C2E00B194F2 /* OFZIPArchiveEntry+Private.h */,
				4B6AF97310A8D4450003FB0A /* ObjFW.h */,
				4BB52CC817B8EA8E00B7EBF5 /* apple-forwarding-arm.S */,
				4BB52CC917B8EA8E00B7EBF5 /* apple-forwarding-i386.S */,
				4BB52CCA17B8EA8E00B7EBF5 /* apple-forwarding-ppc.S */,
				4BB52CCB17B8EA8E00B7EBF5 /* apple-forwarding-x86_64.S */,
				4B6799561099E7C50041064A /* asprintf.h */,
				4B6AF96C10A8D3E40003FB0A /* asprintf.m */,
1549
1550
1551
1552
1553
1554
1555

1556


1557
1558
1559
1560

1561



1562
1563
1564
1565
1566
1567
1568
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596







+

+
+




+

+
+
+







				4B9BB7BD141CDE2D000AD1CC /* OFArray_adjacentSubarray.h in Headers */,
				4BA85BCA140ECCE800E91D51 /* OFCountedSet_hashtable.h in Headers */,
				4B2B3E7F140D430500EC2F7C /* OFDictionary_hashtable.h in Headers */,
				4B2B3E81140D430500EC2F7C /* OFMutableArray_adjacent.h in Headers */,
				4B2B3E83140D430500EC2F7C /* OFMutableDictionary_hashtable.h in Headers */,
				4BA85BCC140ECCE800E91D51 /* OFMutableSet_hashtable.h in Headers */,
				4B552552147AA5DB0003BF47 /* OFMutableString_UTF8.h in Headers */,
				4B6C8AD817BD5C2E00B194F2 /* OFRunLoop+Private.h in Headers */,
				4BA85BCE140ECCE800E91D51 /* OFSet_hashtable.h in Headers */,
				4B6C8AD917BD5C2E00B194F2 /* OFStream+Private.h in Headers */,
				4B6C8ADA17BD5C2E00B194F2 /* OFStreamObserver+Private.h in Headers */,
				4B83F0F4142FDEFD00E4A821 /* OFStreamObserver_kqueue.h in Headers */,
				4B64D6EF1425381E007BDFB1 /* OFStreamObserver_poll.h in Headers */,
				4B64D6F11425381E007BDFB1 /* OFStreamObserver_select.h in Headers */,
				4B552554147AA5DB0003BF47 /* OFString_UTF8.h in Headers */,
				4B6C8ADB17BD5C2E00B194F2 /* OFString_UTF8+Private.h in Headers */,
				4BD653C5143B8489006182F0 /* OFTCPSocket+SOCKS5.h in Headers */,
				4B6C8ADC17BD5C2E00B194F2 /* OFThread+Private.h in Headers */,
				4B6C8ADD17BD5C2E00B194F2 /* OFTimer+Private.h in Headers */,
				4B6C8ADE17BD5C2E00B194F2 /* OFZIPArchiveEntry+Private.h in Headers */,
				4BDF37B51338055600F9A81A /* config.h in Headers */,
			);
			runOnlyForDeploymentPostprocessing = 0;
		};
/* End PBXHeadersBuildPhase section */

/* Begin PBXNativeTarget section */

Modified src/OFApplication.h from [ab2b8913d3] to [bf2d96e316].

165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
165
166
167
168
169
170
171







172
173
174
175
176
177
178







-
-
-
-
-
-
-







/*!
 * @brief Terminates the application with the specified status.
 *
 * @param status The status with which the application will terminate
 */
+ (void)terminateWithStatus: (int)status;

- (void)OF_setArgumentCount: (int*)argc
	  andArgumentValues: (char**[])argv;
#ifdef _WIN32
- (void)OF_setArgumentCount: (int)argc
      andWideArgumentValues: (wchar_t*[])argv;
#endif

/*!
 * @brief Gets args and argv.
 *
 * @param argc A pointer where a pointer to argc should be stored
 * @param argv A pointer where a pointer to argv should be stored
 */
- (void)getArgumentCount: (int**)argc
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
209
210
211
212
213
214
215


216
217
218
219
220
221
222







-
-







/*!
 * @brief Sets the delegate of the application.
 *
 * @param delegate The delegate for the application
 */
- (void)setDelegate: (id <OFApplicationDelegate>)delegate;

- (void)OF_run;

/*!
 * @brief Terminates the application.
 */
- (void)terminate;

/*!
 * @brief Terminates the application with the specified status.

Modified src/OFApplication.m from [4f87ab0c32] to [65cd40e6d2].

23
24
25
26
27
28
29

30

31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49










50
51
52
53
54
55
56
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68







+

+



















+
+
+
+
+
+
+
+
+
+







#include <signal.h>

#import "OFApplication.h"
#import "OFString.h"
#import "OFArray.h"
#import "OFDictionary.h"
#import "OFRunLoop.h"
#import "OFRunLoop+Private.h"
#import "OFThread.h"
#import "OFThread+Private.h"

#import "autorelease.h"
#import "macros.h"

#if defined(__MACH__) && !defined(OF_IOS)
# include <crt_externs.h>
#elif defined(_WIN32)
# include <windows.h>

extern int _CRT_glob;
extern void __wgetmainargs(int*, wchar_t***, wchar_t***, int, int*);
#elif !defined(OF_IOS)
extern char **environ;
#endif

#ifdef _PSP
# include <pspkerneltypes.h>
# include <psploadexec.h>
#endif

@interface OFApplication (OF_PRIVATE_CATEGORY)
- (void)OF_setArgumentCount: (int*)argc
	  andArgumentValues: (char**[])argv;
#ifdef _WIN32
- (void)OF_setArgumentCount: (int)argc
      andWideArgumentValues: (wchar_t*[])argv;
#endif
- (void)OF_run;
@end

static OFApplication *app = nil;

static void
atexit_handler(void)
{
	id <OFApplicationDelegate> delegate = [app delegate];

Modified src/OFHTTPServer.h from [d556b97800] to [7e91272370].

149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
149
150
151
152
153
154
155




156
157
158
159







-
-
-
-





/*!
 * @brief Stops the HTTP server, meaning it will not accept any new incoming
 *	  connections, but still handle existing connections until they are
 *	  finished or timed out.
 */
- (void)stop;

- (bool)OF_socket: (OFTCPSocket*)socket
  didAcceptSocket: (OFTCPSocket*)clientSocket
	exception: (OFException*)exception;
@end

@interface OFObject (OFHTTPServerDelegate) <OFHTTPServerDelegate>
@end

Modified src/OFHTTPServer.m from [ce19d575cc] to [80673ced7f].

42
43
44
45
46
47
48






49
50
51
52
53
54
55
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61







+
+
+
+
+
+








#define BUFFER_SIZE 1024

/*
 * FIXME: Key normalization replaces headers like "DNT" with "Dnt".
 * FIXME: Errors are not reported to the user.
 */

@interface OFHTTPServer (OF_PRIVATE_CATEGORY)
- (bool)OF_socket: (OFTCPSocket*)socket
  didAcceptSocket: (OFTCPSocket*)clientSocket
	exception: (OFException*)exception;
@end

static const char*
status_code_to_string(short code)
{
	switch (code) {
	case 100:
		return "Continue";

Modified src/OFMapTable.h from [260a69baad] to [98d8e166cb].

132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
132
133
134
135
136
137
138




139
140
141
142
143
144
145







-
-
-
-







 * @brief Returns the value for the given key or nil if the key was not found.
 *
 * @param key The key whose object should be returned
 * @return The value for the given key or nil if the key was not found
 */
- (void*)valueForKey: (void*)key;

- (void)OF_setValue: (void*)value
	     forKey: (void*)key
	       hash: (uint32_t)hash;

/*!
 * @brief Sets a value for a key.
 *
 * @param key The key to set
 * @param value The value to set the key to
 */
- (void)setValue: (void*)value
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
234
235
236
237
238
239
240





241
242
243
244
245
246
247







-
-
-
-
-







	struct of_map_table_bucket **_buckets;
	uint32_t _capacity;
	unsigned long _mutations;
	unsigned long *_mutationsPtr;
	uint32_t _position;
}

- OF_initWithMapTable: (OFMapTable*)mapTable
	      buckets: (struct of_map_table_bucket**)buckets
	     capacity: (uint32_t)capacity
     mutationsPointer: (unsigned long*)mutationsPtr;

/*!
 * @brief Returns the next value.
 *
 * @return The next value
 */
- (void*)nextValue;

Modified src/OFMapTable.m from [162f4f232a] to [1f413086d9].

56
57
58
59
60
61
62













63
64
65
66
67
68
69
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
82







+
+
+
+
+
+
+
+
+
+
+
+
+







}

static bool
default_equal(void *value1, void *value2)
{
	return (value1 == value2);
}

@interface OFMapTable (OF_PRIVATE_CATEGORY)
- (void)OF_setValue: (void*)value
	     forKey: (void*)key
	       hash: (uint32_t)hash;
@end

@interface OFMapTableEnumerator (OF_PRIVATE_CATEGORY)
- OF_initWithMapTable: (OFMapTable*)mapTable
	      buckets: (struct of_map_table_bucket**)buckets
	     capacity: (uint32_t)capacity
     mutationsPointer: (unsigned long*)mutationsPtr;
@end

@interface OFMapTableKeyEnumerator: OFMapTableEnumerator
@end

@interface OFMapTableValueEnumerator: OFMapTableEnumerator
@end

Modified src/OFProcess.h from [cb05d48dd9] to [9ddd71d1ba].

160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
160
161
162
163
164
165
166






167
168
169
170
171
172
173
174
175







-
-
-
-
-
-









 * @return An initialized OFProcess.
 */
- initWithProgram: (OFString*)program
      programName: (OFString*)programName
	arguments: (OFArray*)arguments
      environment: (OFDictionary*)environment;

#ifndef _WIN32
- (char**)OF_environmentForDictionary: (OFDictionary*)dictionary;
#else
- (of_char16_t*)OF_environmentForDictionary: (OFDictionary*)dictionary;
#endif

/*!
 * @brief Closes the write direction of the process.
 *
 * This method needs to be called for some programs before data can be read,
 * since some programs don't start processing before the write direction is
 * closed.
 */
- (void)closeForWriting;
@end

Modified src/OFProcess.m from [6a59691f03] to [cf4262ee3c].

44
45
46
47
48
49
50








51
52
53
54
55
56
57
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65







+
+
+
+
+
+
+
+







#endif

#import "autorelease.h"

#ifndef __MACH__
extern char **environ;
#endif

@interface OFProcess (OF_PRIVATE_CATEGORY)
#ifndef _WIN32
- (char**)OF_environmentForDictionary: (OFDictionary*)dictionary;
#else
- (of_char16_t*)OF_environmentForDictionary: (OFDictionary*)dictionary;
#endif
@end

@implementation OFProcess
+ (instancetype)processWithProgram: (OFString*)program
{
	return [[[self alloc] initWithProgram: program] autorelease];
}

Added src/OFRunLoop+Private.h version [596664aa07].




























































1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
/*
 * Copyright (c) 2008, 2009, 2010, 2011, 2012, 2013
 *   Jonathan Schleifer <js@webkeks.org>
 *
 * All rights reserved.
 *
 * This file is part of ObjFW. It may be distributed under the terms of the
 * Q Public License 1.0, which can be found in the file LICENSE.QPL included in
 * the packaging of this file.
 *
 * Alternatively, it may be distributed under the terms of the GNU General
 * Public License, either version 2 or 3, which can be found in the file
 * LICENSE.GPLv2 or LICENSE.GPLv3 respectively included in the packaging of this
 * file.
 */

#import "OFRunLoop.h"

#import "macros.h"

@interface OFRunLoop (OF_PRIVATE_CATEGORY)
+ (void)OF_setMainRunLoop: (OFRunLoop*)runLoop;
#ifdef OF_HAVE_SOCKETS
+ (void)OF_addAsyncReadForStream: (OFStream*)stream
			  buffer: (void*)buffer
			  length: (size_t)length
			  target: (id)target
			selector: (SEL)selector;
+ (void)OF_addAsyncReadForStream: (OFStream*)stream
			  buffer: (void*)buffer
		     exactLength: (size_t)length
			  target: (id)target
			selector: (SEL)selector;
+ (void)OF_addAsyncReadLineForStream: (OFStream*)stream
			    encoding: (of_string_encoding_t)encoding
			      target: (id)target
			    selector: (SEL)selector;
+ (void)OF_addAsyncAcceptForTCPSocket: (OFTCPSocket*)socket
			       target: (id)target
			     selector: (SEL)selector;
# ifdef OF_HAVE_BLOCKS
+ (void)OF_addAsyncReadForStream: (OFStream*)stream
			  buffer: (void*)buffer
			  length: (size_t)length
			   block: (of_stream_async_read_block_t)block;
+ (void)OF_addAsyncReadForStream: (OFStream*)stream
			  buffer: (void*)buffer
		     exactLength: (size_t)length
			   block: (of_stream_async_read_block_t)block;
+ (void)OF_addAsyncReadLineForStream: (OFStream*)stream
			    encoding: (of_string_encoding_t)encoding
			       block: (of_stream_async_read_line_block_t)block;
+ (void)OF_addAsyncAcceptForTCPSocket: (OFTCPSocket*)socket
				block: (of_tcpsocket_async_accept_block_t)block;
# endif
+ (void)OF_cancelAsyncRequestsForStream: (OFStream*)stream;
#endif
- (void)OF_removeTimer: (OFTimer*)timer;
@end

Modified src/OFRunLoop.h from [29f177ef6f] to [9254497b90].

59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
59
60
61
62
63
64
65





































66
67
68
69
70
71
72


73
74
75
76
77
78
79
80
81
82
83







-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-







-
-











/*!
 * @brief Returns the run loop for the current thread.
 *
 * @return The run loop for the current thread
 */
+ (OFRunLoop*)currentRunLoop;

+ (void)OF_setMainRunLoop: (OFRunLoop*)runLoop;
#ifdef OF_HAVE_SOCKETS
+ (void)OF_addAsyncReadForStream: (OFStream*)stream
			  buffer: (void*)buffer
			  length: (size_t)length
			  target: (id)target
			selector: (SEL)selector;
+ (void)OF_addAsyncReadForStream: (OFStream*)stream
			  buffer: (void*)buffer
		     exactLength: (size_t)length
			  target: (id)target
			selector: (SEL)selector;
+ (void)OF_addAsyncReadLineForStream: (OFStream*)stream
			    encoding: (of_string_encoding_t)encoding
			      target: (id)target
			    selector: (SEL)selector;
+ (void)OF_addAsyncAcceptForTCPSocket: (OFTCPSocket*)socket
			       target: (id)target
			     selector: (SEL)selector;
# ifdef OF_HAVE_BLOCKS
+ (void)OF_addAsyncReadForStream: (OFStream*)stream
			  buffer: (void*)buffer
			  length: (size_t)length
			   block: (of_stream_async_read_block_t)block;
+ (void)OF_addAsyncReadForStream: (OFStream*)stream
			  buffer: (void*)buffer
		     exactLength: (size_t)length
			   block: (of_stream_async_read_block_t)block;
+ (void)OF_addAsyncReadLineForStream: (OFStream*)stream
			    encoding: (of_string_encoding_t)encoding
			       block: (of_stream_async_read_line_block_t)block;
+ (void)OF_addAsyncAcceptForTCPSocket: (OFTCPSocket*)socket
				block: (of_tcpsocket_async_accept_block_t)block;
# endif
+ (void)OF_cancelAsyncRequestsForStream: (OFStream*)stream;
#endif

/*!
 * @brief Adds an OFTimer to the run loop.
 *
 * @param timer The timer to add
 */
- (void)addTimer: (OFTimer*)timer;

- (void)OF_removeTimer: (OFTimer*)timer;

/*!
 * @brief Starts the run loop.
 */
- (void)run;

/*!
 * @brief Stops the run loop. If there is still an operation being executed, it
 *	  is finished before the run loop stops.
 */
- (void)stop;
@end

Modified src/OFRunLoop.m from [3252e51e8a] to [ece7ab01e9].

15
16
17
18
19
20
21

22
23
24
25
26
27
28
29
30
31
32

33
34
35
36
37
38
39
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41







+











+







 */

#include "config.h"

#include <assert.h>

#import "OFRunLoop.h"
#import "OFRunLoop+Private.h"
#import "OFDictionary.h"
#ifdef OF_HAVE_SOCKETS
# import "OFStreamObserver.h"
#endif
#import "OFThread.h"
#ifdef OF_HAVE_THREADS
# import "OFMutex.h"
# import "OFCondition.h"
#endif
#import "OFSortedList.h"
#import "OFTimer.h"
#import "OFTimer+Private.h"
#import "OFDate.h"

#import "autorelease.h"
#import "macros.h"

static OFRunLoop *mainRunLoop = nil;

Modified src/OFStdIOStream.h from [b9d05c835c] to [191d7021a4].

23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
23
24
25
26
27
28
29


30
31
32
33
34
35
36







-
-







 * instances of this class and need no initialization.
 */
@interface OFStdIOStream: OFStream
{
	int  _fd;
	bool _atEndOfStream;
}

- (instancetype)OF_initWithFileDescriptor: (int)fd;
@end

#ifdef __cplusplus
extern "C" {
#endif
/*! @file */

Modified src/OFStdIOStream.m from [7fe2743d3d] to [26b8ba6e3e].

27
28
29
30
31
32
33




34
35
36
37
38
39
40
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44







+
+
+
+







#import "OFWriteFailedException.h"

#import "autorelease.h"

OFStdIOStream *of_stdin = nil;
OFStdIOStream *of_stdout = nil;
OFStdIOStream *of_stderr = nil;

@interface OFStdIOStream (OF_PRIVATE_CATEGORY)
- (instancetype)OF_initWithFileDescriptor: (int)fd;
@end

void
of_log(OFConstantString *format, ...)
{
	void *pool = objc_autoreleasePoolPush();
	OFDate *date;
	OFString *dateString, *me, *msg;

Added src/OFStream+Private.h version [ccf2b00bc3].
























1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
/*
 * Copyright (c) 2008, 2009, 2010, 2011, 2012, 2013
 *   Jonathan Schleifer <js@webkeks.org>
 *
 * All rights reserved.
 *
 * This file is part of ObjFW. It may be distributed under the terms of the
 * Q Public License 1.0, which can be found in the file LICENSE.QPL included in
 * the packaging of this file.
 *
 * Alternatively, it may be distributed under the terms of the GNU General
 * Public License, either version 2 or 3, which can be found in the file
 * LICENSE.GPLv2 or LICENSE.GPLv3 respectively included in the packaging of this
 * file.
 */

#import "OFStream.h"

#import "macros.h"

@interface OFStream (OF_PRIVATE_CATEGORY)
- (bool)OF_isWaitingForDelimiter;
@end

Modified src/OFStream.h from [27c14268e9] to [95be3e6746].

1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1091
1092
1093
1094
1095
1096
1097


1098







-
-

 *
 * Override this method with your actual end of stream checking implementation
 * when subclassing!
 *
 * @return Whether the lowlevel is at the end of the stream
 */
- (bool)lowlevelIsAtEndOfStream;

- (bool)OF_isWaitingForDelimiter;
@end

Modified src/OFStream.m from [cfbf6fbabe] to [5586c87ef1].

28
29
30
31
32
33
34

35
36
37
38

39
40
41
42
43
44
45
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47







+




+







#include <fcntl.h>

#ifndef _WIN32
# include <signal.h>
#endif

#import "OFStream.h"
#import "OFStream+Private.h"
#import "OFString.h"
#import "OFDataArray.h"
#import "OFSystemInfo.h"
#import "OFRunLoop.h"
#import "OFRunLoop+Private.h"

#import "OFInvalidArgumentException.h"
#import "OFInvalidFormatException.h"
#import "OFNotImplementedException.h"
#import "OFSetOptionFailedException.h"

#import "macros.h"

Added src/OFStreamObserver+Private.h version [fb91c6b675].





























1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
/*
 * Copyright (c) 2008, 2009, 2010, 2011, 2012, 2013
 *   Jonathan Schleifer <js@webkeks.org>
 *
 * All rights reserved.
 *
 * This file is part of ObjFW. It may be distributed under the terms of the
 * Q Public License 1.0, which can be found in the file LICENSE.QPL included in
 * the packaging of this file.
 *
 * Alternatively, it may be distributed under the terms of the GNU General
 * Public License, either version 2 or 3, which can be found in the file
 * LICENSE.GPLv2 or LICENSE.GPLv3 respectively included in the packaging of this
 * file.
 */

#import "OFStreamObserver.h"

#import "macros.h"

@interface OFStreamObserver (OF_PRIVATE_CATEGORY)
- (void)OF_addFileDescriptorForReading: (int)fd;
- (void)OF_addFileDescriptorForWriting: (int)fd;
- (void)OF_removeFileDescriptorForReading: (int)fd;
- (void)OF_removeFileDescriptorForWriting: (int)fd;
- (void)OF_processQueue;
- (bool)OF_processCache;
@end

Modified src/OFStreamObserver.h from [1ad6295688] to [5f262f5416].

203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
203
204
205
206
207
208
209







210
211
212
213







-
-
-
-
-
-
-




 * @brief Cancels the currently blocking observe call.
 *
 * This is automatically done when a new stream is added or removed by another
 * thread, but in some circumstances, it might be desirable for a thread to
 * manually stop the observe running in another thread.
 */
- (void)cancel;

- (void)OF_addFileDescriptorForReading: (int)fd;
- (void)OF_addFileDescriptorForWriting: (int)fd;
- (void)OF_removeFileDescriptorForReading: (int)fd;
- (void)OF_removeFileDescriptorForWriting: (int)fd;
- (void)OF_processQueue;
- (bool)OF_processCache;
@end

@interface OFObject (OFStreamObserverDelegate) <OFStreamObserverDelegate>
@end

Modified src/OFStreamObserver.m from [2bcf8ed1eb] to [50f0ed1166].

21
22
23
24
25
26
27

28
29
30

31
32
33
34
35
36
37
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39







+



+







#include <stdlib.h>

#include <unistd.h>

#include <assert.h>

#import "OFStreamObserver.h"
#import "OFStreamObserver+Private.h"
#import "OFArray.h"
#import "OFDictionary.h"
#import "OFStream.h"
#import "OFStream+Private.h"
#import "OFDataArray.h"
#ifndef OF_HAVE_PIPE
# import "OFStreamSocket.h"
#endif
#ifdef OF_HAVE_THREADS
# import "OFMutex.h"
#endif

Modified src/OFStreamObserver_kqueue.m from [49f47f6ab0] to [f47615918e].

22
23
24
25
26
27
28


29
30
31
32
33
34
35
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37







+
+








#include <assert.h>

#include <sys/types.h>
#include <sys/event.h>
#include <sys/time.h>

#import "OFStreamObserver.h"
#import "OFStreamObserver+Private.h"
#import "OFStreamObserver_kqueue.h"
#import "OFDataArray.h"

#import "OFInitializationFailedException.h"
#import "OFOutOfMemoryException.h"
#import "OFOutOfRangeException.h"

Modified src/OFStreamObserver_poll.m from [45fcb749cc] to [5dd81a0ef7].

20
21
22
23
24
25
26


27
28
29
30
31
32
33
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35







+
+








#include <unistd.h>

#ifdef HAVE_POLL_H
# include <poll.h>
#endif

#import "OFStreamObserver.h"
#import "OFStreamObserver+Private.h"
#import "OFStreamObserver_poll.h"
#import "OFDataArray.h"

#import "OFOutOfRangeException.h"

#import "autorelease.h"
#import "macros.h"

Modified src/OFStreamObserver_select.m from [855b79f521] to [a17e72c07d].

20
21
22
23
24
25
26


27
28
29
30
31
32
33
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35







+
+








#include <string.h>
#include <math.h>
#include <unistd.h>

#include <sys/time.h>

#import "OFStreamObserver.h"
#import "OFStreamObserver+Private.h"
#import "OFStreamObserver_select.h"
#import "OFStream.h"
#import "OFArray.h"

#import "autorelease.h"
#import "macros.h"

Modified src/OFString.m from [6989417794] to [742f45a0e9].

20
21
22
23
24
25
26

27
28
29
30
31
32
33
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34







+







#include <stdlib.h>
#include <string.h>

#include <sys/stat.h>

#import "OFString.h"
#import "OFString_UTF8.h"
#import "OFString_UTF8+Private.h"
#import "OFArray.h"
#import "OFDictionary.h"
#import "OFFile.h"
#import "OFURL.h"
#ifdef OF_HAVE_SOCKETS
# import "OFHTTPClient.h"
# import "OFHTTPRequest.h"

Added src/OFString_UTF8+Private.h version [ba4698d7e0].


























1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
/*
 * Copyright (c) 2008, 2009, 2010, 2011, 2012, 2013
 *   Jonathan Schleifer <js@webkeks.org>
 *
 * All rights reserved.
 *
 * This file is part of ObjFW. It may be distributed under the terms of the
 * Q Public License 1.0, which can be found in the file LICENSE.QPL included in
 * the packaging of this file.
 *
 * Alternatively, it may be distributed under the terms of the GNU General
 * Public License, either version 2 or 3, which can be found in the file
 * LICENSE.GPLv2 or LICENSE.GPLv3 respectively included in the packaging of this
 * file.
 */

#import "OFString_UTF8.h"

#import "macros.h"

@interface OFString_UTF8 (OF_PRIVATE_CATEGORY)
- (instancetype)OF_initWithUTF8String: (const char*)UTF8String
			       length: (size_t)UTF8StringLength
			      storage: (char*)storage;
@end

Modified src/OFString_UTF8.h from [d53866cce9] to [a4868bc2fd].

33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
33
34
35
36
37
38
39




40
41
42
43
44
45
46
47
48
49
50







-
-
-
-











		size_t	 length;
		bool	 hashed;
		uint32_t hash;
		char	 *freeWhenDone;
	} *restrict _s;
	struct of_string_utf8_ivars _storage;
}

- (instancetype)OF_initWithUTF8String: (const char*)UTF8String
			       length: (size_t)UTF8StringLength
			      storage: (char*)storage;
@end

#ifdef __cplusplus
extern "C" {
#endif
extern int of_string_utf8_check(const char*, size_t, size_t*);
extern size_t of_string_utf8_get_index(const char*, size_t);
extern size_t of_string_utf8_get_position(const char*, size_t, size_t);
#ifdef __cplusplus
}
#endif

Modified src/OFString_UTF8.m from [dcb1103ce6] to [33807e1aeb].

20
21
22
23
24
25
26

27
28
29
30
31
32
33
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34







+







#include <stdlib.h>
#include <string.h>
#include <ctype.h>

#include <sys/types.h>

#import "OFString_UTF8.h"
#import "OFString_UTF8+Private.h"
#import "OFMutableString_UTF8.h"
#import "OFArray.h"

#import "OFInitializationFailedException.h"
#import "OFInvalidArgumentException.h"
#import "OFInvalidEncodingException.h"
#import "OFInvalidFormatException.h"

Modified src/OFTCPSocket.m from [68c36aac7d] to [bc0a6e3581].

37
38
39
40
41
42
43

44
45
46
47
48
49
50
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51







+








#import "OFTCPSocket.h"
#import "OFTCPSocket+SOCKS5.h"
#import "OFString.h"
#import "OFThread.h"
#import "OFTimer.h"
#import "OFRunLoop.h"
#import "OFRunLoop+Private.h"

#import "OFAcceptFailedException.h"
#import "OFAlreadyConnectedException.h"
#import "OFAddressTranslationFailedException.h"
#import "OFBindFailedException.h"
#import "OFConnectionFailedException.h"
#import "OFInvalidArgumentException.h"

Added src/OFThread+Private.h version [b0ccbc3e19].
























1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
/*
 * Copyright (c) 2008, 2009, 2010, 2011, 2012, 2013
 *   Jonathan Schleifer <js@webkeks.org>
 *
 * All rights reserved.
 *
 * This file is part of ObjFW. It may be distributed under the terms of the
 * Q Public License 1.0, which can be found in the file LICENSE.QPL included in
 * the packaging of this file.
 *
 * Alternatively, it may be distributed under the terms of the GNU General
 * Public License, either version 2 or 3, which can be found in the file
 * LICENSE.GPLv2 or LICENSE.GPLv3 respectively included in the packaging of this
 * file.
 */

#import "OFThread.h"

#import "macros.h"

@interface OFThread (OF_PRIVATE_CATEGORY)
+ (void)OF_createMainThread;
@end

Modified src/OFThread.h from [1a40d77417] to [79574f891b].

147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
147
148
149
150
151
152
153


154
155
156
157
158
159
160







-
-







/*!
 * @brief Terminates the current thread, letting it return the specified object.
 *
 * @param object The object which the terminated thread will return
 */
+ (void)terminateWithObject: (id)object;

+ (void)OF_createMainThread;

# ifdef OF_HAVE_BLOCKS
/*!
 * @brief Initializes an already allocated thread with the specified block.
 *
 * @param threadBlock A block which is executed by the thread
 * @return An initialized OFThread.
 */

Modified src/OFThread.m from [c78e4c4d29] to [a7b179a03a].

33
34
35
36
37
38
39
40
41



42
43
44
45
46
47
48
33
34
35
36
37
38
39


40
41
42
43
44
45
46
47
48
49







-
-
+
+
+







# include <sched.h>
#endif

#if defined(OF_HAVE_THREADS) && defined(__HAIKU__)
# include <kernel/OS.h>
#endif

#import "OFRunLoop.h"
#import "OFThread.h"
#import "OFThread.h"
#import "OFThread+Private.h"
#import "OFRunLoop.h"
#import "OFList.h"
#import "OFDate.h"
#import "OFDictionary.h"
#import "OFAutoreleasePool.h"

#ifdef _WIN32
# include <windows.h>

Added src/OFTimer+Private.h version [a31ad4eb72].
























1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
/*
 * Copyright (c) 2008, 2009, 2010, 2011, 2012, 2013
 *   Jonathan Schleifer <js@webkeks.org>
 *
 * All rights reserved.
 *
 * This file is part of ObjFW. It may be distributed under the terms of the
 * Q Public License 1.0, which can be found in the file LICENSE.QPL included in
 * the packaging of this file.
 *
 * Alternatively, it may be distributed under the terms of the GNU General
 * Public License, either version 2 or 3, which can be found in the file
 * LICENSE.GPLv2 or LICENSE.GPLv3 respectively included in the packaging of this
 * file.
 */

#import "OFTimer.h"

#import "macros.h"

@interface OFTimer (OF_PRIVATE_CATEGORY)
- (void)OF_setInRunLoop: (OFRunLoop*)inRunLoop;
@end

Modified src/OFTimer.h from [ca397382d3] to [8545154a8d].

324
325
326
327
328
329
330
331
332
333
324
325
326
327
328
329
330


331







-
-


#ifdef OF_HAVE_THREADS
/*!
 * @brief Waits until the timer fired.
 */
- (void)waitUntilDone;
#endif

- (void)OF_setInRunLoop: (OFRunLoop*)inRunLoop;
@end

Modified src/OFTimer.m from [39f8a0b5fa] to [cab4d43241].

17
18
19
20
21
22
23

24
25

26
27
28
29
30
31
32
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34







+


+







#include "config.h"

#include <stdlib.h>

#include <assert.h>

#import "OFTimer.h"
#import "OFTimer+Private.h"
#import "OFDate.h"
#import "OFRunLoop.h"
#import "OFRunLoop+Private.h"
#ifdef OF_HAVE_THREADS
# import "OFCondition.h"
#endif

#import "OFInvalidArgumentException.h"

#import "autorelease.h"

Modified src/OFZIPArchive.h from [da67b3e3b1] to [2b8cc476e1].

78
79
80
81
82
83
84
85
86
87
88
78
79
80
81
82
83
84



85







-
-
-

/*!
 * @brief Returns a stream for reading the specified file from the archive.
 *
 * @param path The path to the file inside the archive
 * @return A stream for reading the specified file form the archive
 */
- (OFStream*)streamForReadingFile: (OFString*)path;

- (void)OF_readZIPInfo;
- (void)OF_readEntries;
@end

Modified src/OFZIPArchive.m from [8fc2a5d079] to [fe6bfd47af].

16
17
18
19
20
21
22

23
24
25
26
27
28
29
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30







+








#include "config.h"

#include <stdio.h>

#import "OFZIPArchive.h"
#import "OFZIPArchiveEntry.h"
#import "OFZIPArchiveEntry+Private.h"
#import "OFDictionary.h"
#import "OFFile.h"

#import "OFChecksumFailedException.h"
#import "OFInvalidArgumentException.h"
#import "OFInvalidFormatException.h"
#import "OFNotImplementedException.h"
42
43
44
45
46
47
48





49
50
51
52
53
54
55
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61







+
+
+
+
+







 *  - Encrypted files cannot be read.
 *  - Split archives are not supported.
 *  - Write support is missing.
 *  - The ZIP has to be a file on the local file system.
 *  - No support for ZIP64.
 *  - No support for data descriptors (useless without compression anyway).
 */

@interface OFZIPArchive (OF_PRIVATE_CATEGORY)
- (void)OF_readZIPInfo;
- (void)OF_readEntries;
@end

@interface OFZIPArchive_LocalFileHeader: OFObject
{
@public
	uint16_t _minVersion, _generalPurposeBitFlag, _compressionMethod;
	uint16_t _lastModifiedFileTime, _lastModifiedFileDate;
	uint32_t _CRC32, _compressedSize, _uncompressedSize;

Added src/OFZIPArchiveEntry+Private.h version [dbac724b50].



































1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
/*
 * Copyright (c) 2008, 2009, 2010, 2011, 2012, 2013
 *   Jonathan Schleifer <js@webkeks.org>
 *
 * All rights reserved.
 *
 * This file is part of ObjFW. It may be distributed under the terms of the
 * Q Public License 1.0, which can be found in the file LICENSE.QPL included in
 * the packaging of this file.
 *
 * Alternatively, it may be distributed under the terms of the GNU General
 * Public License, either version 2 or 3, which can be found in the file
 * LICENSE.GPLv2 or LICENSE.GPLv3 respectively included in the packaging of this
 * file.
 */

#import "OFZIPArchive.h"

#import "macros.h"

@interface OFZIPArchiveEntry (OF_PRIVATE_CATEGORY)
- (instancetype)OF_initWithFile: (OFFile*)file;
- (uint16_t)OF_madeWithVersion;
- (uint16_t)OF_minVersion;
- (uint16_t)OF_generalPurposeBitFlag;
- (uint16_t)OF_compressionMethod;
- (uint16_t)OF_lastModifiedFileTime;
- (uint16_t)OF_lastModifiedFileDate;
- (OFDataArray*)OF_extraField;
- (uint16_t)OF_startDiskNumber;
- (uint16_t)OF_internalAttributes;
- (uint32_t)OF_externalAttributes;
- (uint32_t)OF_localFileHeaderOffset;
@end

Modified src/OFZIPArchiveEntry.h from [0761b5b8e6] to [7e3c51448d].

43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
43
44
45
46
47
48
49


50
51
52
53
54
55
56







-
-







#ifdef OF_HAVE_PROPERTIES
@property (readonly, copy) OFString *fileName, *fileComment;
@property (readonly) off_t compressedSize, uncompressedSize;
@property (readonly, retain) OFDate *modificationDate;
@property (readonly) uint32_t CRC32;
#endif

- (instancetype)OF_initWithFile: (OFFile*)file;

/*!
 * @brief Returns the file name of the entry.
 *
 * @return The file name of the entry
 */
- (OFString*)fileName;

86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
84
85
86
87
88
89
90












91







-
-
-
-
-
-
-
-
-
-
-
-


/*!
 * @brief Returns the CRC32 checksum of the entry's file.
 *
 * @return The CRC32 checksum of the entry's file
 */
- (uint32_t)CRC32;

- (uint16_t)OF_madeWithVersion;
- (uint16_t)OF_minVersion;
- (uint16_t)OF_generalPurposeBitFlag;
- (uint16_t)OF_compressionMethod;
- (uint16_t)OF_lastModifiedFileTime;
- (uint16_t)OF_lastModifiedFileDate;
- (OFDataArray*)OF_extraField;
- (uint16_t)OF_startDiskNumber;
- (uint16_t)OF_internalAttributes;
- (uint32_t)OF_externalAttributes;
- (uint32_t)OF_localFileHeaderOffset;
@end

Modified src/OFZIPArchiveEntry.m from [fabc446b26] to [24e2aa1cb7].

13
14
15
16
17
18
19

20
21
22
23
24
25
26
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27







+







 * LICENSE.GPLv2 or LICENSE.GPLv3 respectively included in the packaging of this
 * file.
 */

#include "config.h"

#import "OFZIPArchiveEntry.h"
#import "OFZIPArchiveEntry+Private.h"
#import "OFString.h"
#import "OFDataArray.h"
#import "OFFile.h"
#import "OFDate.h"

#import "autorelease.h"
#import "macros.h"

Modified src/macros.h from [171260d70c] to [086b67ded9].

127
128
129
130
131
132
133






134
135
136
137
138
139
140
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146







+
+
+
+
+
+







extern void objc_setProperty(id, SEL, ptrdiff_t, id, BOOL, signed char);

#define OF_IVAR_OFFSET(ivar) ((intptr_t)&ivar - (intptr_t)self)
#define OF_GETTER(ivar, atomic) \
	return objc_getProperty(self, _cmd, OF_IVAR_OFFSET(ivar), atomic);
#define OF_SETTER(ivar, value, atomic, copy) \
	objc_setProperty(self, _cmd, OF_IVAR_OFFSET(ivar), value, atomic, copy);

#ifdef OF_HAVE_CLASS_EXTENSIONS
# define OF_PRIVATE_CATEGORY
#else
# define OF_PRIVATE_CATEGORY Private
#endif

static OF_INLINE uint16_t OF_CONST_FUNC
OF_BSWAP16_CONST(uint16_t i)
{
	return (i & UINT16_C(0xFF00)) >> 8 |
	    (i & UINT16_C(0x00FF)) << 8;
}