Re: [lwip-users] Call tcp_close() out of tcp_recv()-context?
From:
Karl Karpfen
Subject:
Re: [lwip-users] Call tcp_close() out of tcp_recv()-context?
Date:
Mon, 7 Sep 2015 14:48:47 +0200
2015-09-07 14:17 GMT+02:00 Sergio R. Caprile <address@hidden>:
It depends on what you mean by "context".
The structure is as follows (all non-OS and with RAW API):
With tcp_recv() I set up a receive-callback function my_recv(). my_recv() is triggered by lwIP whenever some data are received. Some of these data may contain an information "connection will be closed by host".
My question: can I do a tcp_close() from within my_recv() which is called in lwIP's receive-context (which possibly may be a receive-IRQ)?