|
From: | address@hidden |
Subject: | Re: [lwip-devel] [task #14395] recv of short buffer should eventually time out |
Date: | Thu, 2 Mar 2017 20:07:22 +0100 |
User-agent: | Mozilla/5.0 (Windows NT 6.1; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.7.2 |
Answering on the list since this is off-topic to the task: Joel Cunningham:
Follow-up Comment #5, task #14395 (project lwip): I've done some auditing of this behavior in LwIP and wanted to share a couple of things: My port has LWIP_SO_RCVTIMEO enabled and for sockets that don't set SO_RCVTIMEO, it uses 0 for a timeout, thus providing the behavior of returning whatever is in the conn->recvmbox and not blocking.
If I understood this right, your port is wrong:In the lwIP sys_arch port layer, a timeout of 0 for lwIP arch does not mean "don't wait" but "wait forever".
"Don't wait" is only done through the "tryfetch/tryget" functions. Simon
[Prev in Thread] | Current Thread | [Next in Thread] |