lwip-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[lwip-users] MEMP_TCP_SEG leak


From: Per-Henrik Lundblom
Subject: [lwip-users] MEMP_TCP_SEG leak
Date: Tue, 5 Nov 2013 08:46:49 +0100
User-agent: Mutt/1.5.20 (2009-06-14)

Hi,

I'm using a pretty old lwIP version and identified a problem with
leaking MEMP_TCP_SEGs. Reading the lwIP mailing list achives I found at
least two other threads regarding this issue but the only fixes in the
latest code versions are the addition of a few asserts for the fault
conditions.

Problem arises for me with TCP on bad WLAN links. The end result is that
I get an incoming TCP packet through tcp_input(), (recv_flags &
TF_CLOSED) is true, tcp_pcb_remove() is called. In turn tcp_pcb_purge()
is called but at this point, (pcb->state == CLOSED) and the pcb->unsent
and pcb->unacked queues are not freed. End result is that these segments
are lost.

The asserts added a couple of years ago can be found in tcp_pcb_remove()
but I see no real cure for the problem. Analyzing the code I have a hard
time to understand why the unsent and unacked queues aren't freed in
tcp_pcb_purge() when in state CLOSED.

Any input on this?

Regards,

PH

--
Per-Henrik Lundblom           email: address@hidden
phone: +46 733 207126         webpage: www.whatever.nu





reply via email to

[Prev in Thread] Current Thread [Next in Thread]