* [MPTCP] Re: [PATCH] self-tests: catch poll errors
@ 2019-10-30 10:43 Florian Westphal
0 siblings, 0 replies; 2+ messages in thread
From: Florian Westphal @ 2019-10-30 10:43 UTC (permalink / raw)
To: mptcp
[-- Attachment #1: Type: text/plain, Size: 406 bytes --]
Paolo Abeni <pabeni(a)redhat.com> wrote:
> Otherwise in case of a poll error, we end-up looping forever.
Did you see this happen in practice?
> + if (fds.revents & (POLLERR | POLLNVAL)) {
> + perror("poll");
errno should be 0 in this case, as poll had revents, i.e. this shows
"poll: success"
Maybe fprintf(stderr, "Unexpected revents: POLLERR/POLLNVAL (%x)\n",
fds.revents); or similar?
^ permalink raw reply [flat|nested] 2+ messages in thread
* [MPTCP] Re: [PATCH] self-tests: catch poll errors
@ 2019-10-30 14:09 Paolo Abeni
0 siblings, 0 replies; 2+ messages in thread
From: Paolo Abeni @ 2019-10-30 14:09 UTC (permalink / raw)
To: mptcp
[-- Attachment #1: Type: text/plain, Size: 597 bytes --]
On Wed, 2019-10-30 at 11:43 +0100, Florian Westphal wrote:
> Paolo Abeni <pabeni(a)redhat.com> wrote:
> > Otherwise in case of a poll error, we end-up looping forever.
>
> Did you see this happen in practice?
I got stuck a couple of times while testing buggy patches.
> > + if (fds.revents & (POLLERR | POLLNVAL)) {
> > + perror("poll");
>
> errno should be 0 in this case, as poll had revents, i.e. this shows
> "poll: success"
>
> Maybe fprintf(stderr, "Unexpected revents: POLLERR/POLLNVAL (%x)\n",
> fds.revents); or similar?
Yep, will do on v2.
Thanks,
Paolo
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2019-10-30 14:09 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-10-30 10:43 [MPTCP] Re: [PATCH] self-tests: catch poll errors Florian Westphal
-- strict thread matches above, loose matches on Subject: below --
2019-10-30 14:09 Paolo Abeni
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.