[Live-devel] MORE: Memory leaks in DarwinInjector.cpp
eyal.b at mavix.com
eyal.b at mavix.com
Mon Nov 19 13:38:47 PST 2007
Yes you are right about item 2, the one that allocates is the one to
de-allocate. The problem is that RTSPClient uses the MediaSubsession as it
own repository for the allocated sub-session id. It only keeps a copy
(strDup) of the last sub-session id. So it has no way of keeping track of
what it had allocated.
I have no "Object Oriented" remedy to that, just the knowledge of the need
to call TearDown() before destroying a session object.
Eyal Beit-Halachmi
-----Original Message-----
From: Ross Finlayson [mailto:finlayson at live555.com]
Sent: Friday, November 16, 2007 7:05 PM
To: LIVE555 Streaming Media - development & use
Subject: Re: [Live-devel] MORE: Memory leaks in DarwinInjector.cpp
The next version of gthe "LIVE555 Streaming Media" code - to be
released probably within a day or so - will include your suggested
changes 1) and 3).
However, I won't be making your suggested change 2/. The "sessionId"
field of "MediaSession" is one of a few fields that are not managed
by the "MediaSession" object itself (note "MediaSession.hh").
Instead, it is managed/assigned externally. (See, e.g.,
"RTSPClient.cpp".) If you allocate memory to assign to the
"sessionId" field, then you are also responsible for deleting that
memory.
--
Ross Finlayson
Live Networks, Inc.
http://www.live555.com/
More information about the live-devel
mailing list