ObjFW  Check-in [e9f870cfc0]

Overview
Comment:When closing an OFTCPSocket, set it's internal socket to -1.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: e9f870cfc061bae1c9aa52d02e3f1b7bc35d272ceb956a8b3ccac9b7bebe5d53
User & Date: js on 2008-12-10 17:54:22
Other Links: manifest | tags
Context
2008-12-10
18:00
Enhance exceptions; fix some FIXMEs in OFTCPSocket. check-in: a01c94d9dd user: js tags: trunk
17:54
When closing an OFTCPSocket, set it's internal socket to -1. check-in: e9f870cfc0 user: js tags: trunk
17:53
Always use [self alloc] in + new.
This way, derivated classes are not forced to always override + new.
check-in: f48ee629e3 user: js tags: trunk
Changes

Modified src/OFTCPSocket.m from [5f52ffb737] to [594dc2652b].

282
283
284
285
286
287
288


289
290
291
292
293
294
295
296
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298







+
+









- close
{
	if (sock < 0) {
		/* FIXME: Throw exception */
		return nil;
	}

	sock = -1;

	if (saddr != NULL)
		[self freeMem: saddr];
	saddr_len = 0;

	return self;
}
@end