buglwIP - A Lightweight TCP/IP stack - Bugs: bug #55477, possible memory leak with sockets

 
 

You are not allowed to post comments on this tracker with your current authentication level.

bug #55477: possible memory leak with sockets

Submitter:  Michael Zimmers <mzimmers>
Submitted:  Mon 14 Jan 2019 11:26:11 PM UTC
   
 
Category:  sockets/netconn Severity:  3 - Normal
Item Group:  Faulty Behaviour Status:  Invalid
Privacy:  Public Assigned to:  None
Open/Closed:  Closed Planned Release:  None
lwIP version:  Other

Tue 15 Jan 2019 05:50:49 PM UTC, comment #1: 

Found the problem -- as a networking newbie, I didn't realize that I needed to call freeaddrinfo() after using getaddrinfo(), and the example I borrowed from didn't have that.

Can someone please either delete my bug report, or mark it as cockpit error? I'd do it myself, but I don't know how...

Michael Zimmers <mzimmers>
Mon 14 Jan 2019 11:26:11 PM UTC, original submission:  

Hi all -

I'm using lwIP from FreeRTOS within the ES32 IDF. Inside a file called VERSION is "bf7fc41e" and the latest entry in CHANGELOG is   2016-02-22: Ivan Delamer:
  * Initial 6LoWPAN support

I hope that adequately pinpoints the version I'm using.

Anyway, I've written a app that uses sockets for UDP multicast communications. Eventually I noticed I was suffering a memory leak. I've reduced the app to a loop that:

1. starts Wifi
2. opens a socket
3. closes the socket
4. stops Wifi

Each iteration of this loop consumes about 800 bytes of heap.

I have no idea where to go from here. I do have a sample program (one include file; two source files) that demonstrates the problem, but it's ESP32 dependent. Is it appropriate to log this as a bug here before I'm sure the problem resides with lwIP?

Thanks for any guidance.

Michael Zimmers <mzimmers>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by goldsimon (Updated the item)
  • -email is unavailable- added by mzimmers (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

     

    Follow 2 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2019-01-15 goldsimon StatusNone Invalid
        Open/ClosedOpen Closed

    Back to the top

    Powered by Savane 3.13-4448.
    Corresponding source code