[Ns-bugs] [Bug 134] TCP code leaks memory

bugzilla-daemon@nsnam-www.ece.gatech.edu bugzilla-daemon at nsnam-www.ece.gatech.edu
Mon Feb 25 14:22:26 PST 2008


http://www.nsnam.org/bugzilla/show_bug.cgi?id=134


raj.b at gatech.edu changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED




------- Comment #3 from raj.b at gatech.edu  2008-02-25 17:22 -------
TCP simulations now valgrind cleanly.  Fixed in 2353:5a1149f7de4e and
2354:ba9d1cad1a7c.

Summary:
When Simulator::Destroy is called, the call stack makes its way down to
TcpSocket::Destroy.  If m_retxEvent.Cancel() is NOT called here (if its called
in ~TcpSocket), then when ~TcpSocket is eventually hit, the simulator has
already been destroyed, and the call to Simulator::Cancel actually CREATES a
new SimulatorPrivate just before the program exits, causing the simulation to
"leak".  The first change set fixes this issue. 

The second fixes some faulty memory management when pulling out copies of
packets from TCPs outgoing TX buffer.


-- 
Configure bugmail: http://www.nsnam.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.


More information about the Ns-bugs mailing list