lwip_close(): call netconn_delete() under socksem to properly handle

concurrent closes.
This commit is contained in:
marcbou 2007-08-16 20:08:33 +00:00
parent 17f07a36ef
commit a3c3f47e17

View File

@ -299,9 +299,9 @@ lwip_close(int s)
return -1;
}
sys_sem_wait(socksem);
netconn_delete(sock->conn);
sys_sem_wait(socksem);
if (sock->lastdata) {
netbuf_delete(sock->lastdata);
}