[prev in list] [next in list] [prev in thread] [next in thread]
List: busybox
Subject: Re: httpd spins madly
From: Laurent Bercot <ska-dietlibc () skarnet ! org>
Date: 2013-09-11 13:06:31
Message-ID: 52306AD7.6000507 () skarnet ! org
[Download RAW message or body]
> I take it from your bug report that having pfd[0].events zeroed
> doesn't prevent POLLHUP|POLLERR from being reported :(
Hi Denys,
POSIX says:
> If the value of fd is less than 0, events shall be ignored, andrevents shall be set \
> to 0 in that entry on return from poll(). In each pollfd structure, poll() shall \
> clear the revents member, except that where the application requested a report on a \
> condition by setting one of the bits of events listed above, poll() shall set the \
> corresponding bit in revents if the requested condition is true. In addition, \
> poll() shall set the POLLHUP, POLLERR, and POLLNVAL flag in revents if the \
> condition is true, even if the application did not set the corresponding bit in \
> events.
If you want to ignore pfd[0] at some point, perform pfd[0] = -1.
--
Laurent
_______________________________________________
busybox mailing list
busybox@busybox.net
http://lists.busybox.net/mailman/listinfo/busybox
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic