valgrind stuff
Brandon Black
blblack at gmail.com
Thu Apr 10 00:34:22 CEST 2008
Marc Lehmann wrote:
> On Wed, Apr 09, 2008 at 04:40:23PM -0500, Brandon Black <blblack at gmail.com> wrote:
>> Here's an interesting thread from another list regarding this exact same
>> problem:
>>
>> http://lists.freedesktop.org/archives/dbus/2006-September/005724.html
>>
>> I'm still a little hazy on what the "right" answer is here, as I'm not a
>> poll() expert, but something like this may be the answer:
>
> poll() is required to clear the revents field.
>
> however, if any real-world systems don't do that on timeout, I'd be happy to
> include a workaround, the cost would be negligible.
>
> (in fact, I might add it in any case, but please, could somebody find out a
> bit more evidence? thanks :)
>
My reading of that other thread I quoted is basically (a) the standard
is self-contradictory, (b) some systems definitely don't clear revents
when they poll() returns zero (what I'm seeing), and (c) there's really
no point looking at revents when poll returns zero, as this means there
are zero events to look at anyways.
-- Brandon
More information about the libev
mailing list