[riot-notifications] [RIOT-OS/RIOT] gcoap server breaks or becomes very unresponsive (sock_async related?) (#14034)
notifications at github.com
Mon May 11 11:52:07 CEST 2020
> There would still be the racy case where a new UDP message arrives just before returning from the handler, but after the decision was made to return. Wouldn't that imply the UDP layer must ensure firing another event if there is still data left after the callback returned?
Good observation. I didn't identify exactly the how the producer/consumer interaction causes the backup. I expect @miri64 will have the insight to point us in the right direction.
> The while-condition in your fix (`while (type & SOCK_ASYNC_MSG_RECV)`) looks a bit strange to me.
I agree it's not idiomatic. ;-) I basically was just combining the while loop into the event type conditional as an optimization to save a statement. The handler does not react to any other event types. At least a short comment would be good to explain.
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the notifications