ObjFW  Check-in [6d9854419c]

Overview
Comment:OPEN_MAX is not available on every system.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: 6d9854419ccad9ad95bddbc5c28decf5582ae466fb26c564a60fb3bd363286b1
User & Date: js on 2011-04-03 19:25:29
Other Links: manifest | tags
Context
2011-04-03
19:52
Add -[pendingBytes] to OFStream. check-in: f4151a36e3 user: js tags: trunk
19:25
OPEN_MAX is not available on every system. check-in: 6d9854419c user: js tags: trunk
19:16
We always need those includes now. check-in: 9db7215004 user: js tags: trunk
Changes

Modified src/OFStreamObserver.m from [9e9e13990f] to [68c03424f8].

374
375
376
377
378
379
380

381
382

383
384
385
386
387
388
389
	if (foundInCache)
		return YES;

#ifdef OF_HAVE_POLL
	fds_c = [fds cArray];
	nfds = [fds count];


	if (nfds > OPEN_MAX)
		@throw [OFOutOfRangeException newWithClass: isa];


	if (poll(fds_c, (nfds_t)nfds, timeout) < 1)
		return NO;

	for (i = 0; i < nfds; i++) {
		OFNumber *num;
		OFStream *stream;







>


>







374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
	if (foundInCache)
		return YES;

#ifdef OF_HAVE_POLL
	fds_c = [fds cArray];
	nfds = [fds count];

# ifdef OPEN_MAX
	if (nfds > OPEN_MAX)
		@throw [OFOutOfRangeException newWithClass: isa];
# endif

	if (poll(fds_c, (nfds_t)nfds, timeout) < 1)
		return NO;

	for (i = 0; i < nfds; i++) {
		OFNumber *num;
		OFStream *stream;