-->
Page 2 of 3

Re: memory leak ??

PostPosted: Mon Apr 20, 2015 12:37 am
by mharizanov
Same here, and with each new SDK version the available heap size seems to be less and less, so this is an issue.
Hitting F5 20 times crashes the server now, looking forward to tips on solving this :)

Re: memory leak ??

PostPosted: Mon Apr 20, 2015 2:53 am
by Sprite_tm
Aaaah, I just tried it and I indeed am not freeing the template generator data. It's only 96 bytes, but it adds up over time. I've added the missing free and I now the memory on the heap happily bounces back to what it should be. I've committed the change to git if you want to test it.

Re: memory leak ??

PostPosted: Tue Apr 21, 2015 4:23 am
by mharizanov
I tried the patch, but the leaks continue; using SDK 0.9.5;
I assume there is more to that, and I am afraid it could be SDK issue rather than esphttpd issue..

Re: memory leak ??

PostPosted: Tue Apr 21, 2015 4:39 am
by mharizanov
.. to answer myself: just tried it with SDK 1.0 and it seems stable now. Although SDK 1.0 uses 2K more heap (at least), it is handling better the TCP connections and the leak seems to be gone now, or at least for the 10 minutes of testing that I have been doing ;)