marc walrave wrote:
do_close_internal internally :-) calls tcp_close
Depending on the pcb state tcp_close potentially frees the pcb of the
netconn struct (via memp_free) for which do_close_internal was called
(tcp_close then returns ERR_OK).
Now after the tcp_close function returns dl_close_internal still
references the pcb pointer as if it was NOT freed?
[snip]
Is this a "genuine" bug or am I missing something "really" subtle here?
Your analysis seems sound. Care to submit a patch at
https://savannah.nongnu.org/patch/?group=lwip ?
Or alternatively file a bug on savannah so this issue isn't lost.