|
From: | Jonathan Larmour |
Subject: | Re: [lwip-devel] MEMP_TCP_SEG somehow being leaked so that they never become available for reuse. |
Date: | Fri, 20 Apr 2007 15:39:45 +0100 |
User-agent: | Thunderbird 1.5.0.10 (X11/20070301) |
geckook Xu wrote:
When I make a lot of connections to the server, the server's lwip stack MEMP_TCP_SEG will be leaked.at this time, the TCP_PCB is 0, and PBUF have the same number of EMP_TCP_SEG.I think if it is because when release the TCP_PCB ,but didn't release the TCP_SEG.
The code certainly does release TCP SEGs in both the unsent and unacked queues in tcp_abort() and tcp_pcb_remove().
How are you closing the connection? If you call tcp_close() and the connection is in the ESTABLISHED state, it will not free up the SEGs immediately. It needs to complete the closing process.
Jifl -- eCosCentric Limited http://www.eCosCentric.com/ The eCos experts Barnwell House, Barnwell Drive, Cambridge, UK. Tel: +44 1223 245571 Registered in England and Wales: Reg No 4422071. ------["The best things in life aren't things."]------ Opinions==mine
[Prev in Thread] | Current Thread | [Next in Thread] |