lwip-devel
[Top][All Lists]
Advanced

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

Re: AW: AW: [lwip-devel] Memory leak for timeouts


From: Jonathan Larmour
Subject: Re: AW: AW: [lwip-devel] Memory leak for timeouts
Date: Tue, 06 Nov 2007 16:45:51 +0000
User-agent: Thunderbird 1.5.0.12 (X11/20070530)

Goldschmidt Simon wrote:
>  
>>> This is indeed a problem if you create and destroy threads at
> runtime.
>>> However, the lwIP sys layer is designed to never end a running thread
> 
>>> (as most embedded systems do), so this is not a problem for most
> users.
>> Actually that's not true if you use select(), which can call
> sys_sem_wait_timeout(), which calls sys_timeout().
> 
> What is not true? I you don't have memory leaks if you don't end
> threads. Of course you have to make sure you allocate the timeout struct
> only once...

The lwIP sys layer is used to create lwIP's own system threads. Application
threads that the user creates may use select(), and lwIP has no knowledge
of when they are created and deleted. So while saying that "the lwIP sys
layer is designed to never end a running thread" is true, it does not
follow "so this is not a problem for most users."

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.
------["Si fractum non sit, noli id reficere"]------       Opinions==mine




reply via email to

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