mirror of
https://github.com/lwip-tcpip/lwip.git
synced 2025-02-06 09:39:59 +00:00
Fixed bug #27709: conn->err race condition on netconn_recv() timeout by directly returning when sys_arch_mbox_fetch times out.
This commit is contained in:
parent
2dc027401f
commit
a9740c6a44
@ -43,6 +43,10 @@ HISTORY
|
|||||||
|
|
||||||
++ Bugfixes:
|
++ Bugfixes:
|
||||||
|
|
||||||
|
2009-10-15: Simon Goldschmidt
|
||||||
|
* api_msg.c: Fixed bug #27709: conn->err race condition on netconn_recv()
|
||||||
|
timeout
|
||||||
|
|
||||||
2009-10-15: Simon Goldschmidt
|
2009-10-15: Simon Goldschmidt
|
||||||
* autoip.c: Fixed bug #27704: autoip starts with wrong address
|
* autoip.c: Fixed bug #27704: autoip starts with wrong address
|
||||||
LWIP_AUTOIP_CREATE_SEED_ADDR() returned address in host byte order instead
|
LWIP_AUTOIP_CREATE_SEED_ADDR() returned address in host byte order instead
|
||||||
|
@ -327,8 +327,9 @@ netconn_recv(struct netconn *conn)
|
|||||||
|
|
||||||
#if LWIP_SO_RCVTIMEO
|
#if LWIP_SO_RCVTIMEO
|
||||||
if (sys_arch_mbox_fetch(conn->recvmbox, (void *)&p, conn->recv_timeout)==SYS_ARCH_TIMEOUT) {
|
if (sys_arch_mbox_fetch(conn->recvmbox, (void *)&p, conn->recv_timeout)==SYS_ARCH_TIMEOUT) {
|
||||||
|
memp_free(MEMP_NETBUF, buf);
|
||||||
conn->err = ERR_TIMEOUT;
|
conn->err = ERR_TIMEOUT;
|
||||||
p = NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
#else
|
#else
|
||||||
sys_arch_mbox_fetch(conn->recvmbox, (void *)&p, 0);
|
sys_arch_mbox_fetch(conn->recvmbox, (void *)&p, 0);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user