[vlc-commits] demux: playlistmanager: fix leak or double free
Francois Cartegnie
git at videolan.org
Mon Nov 9 11:04:51 CET 2015
vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Sat Nov 7 15:06:59 2015 +0100| [24b586c766ad7a674d962f2b131d5dec0674cc2e] | committer: Francois Cartegnie
demux: playlistmanager: fix leak or double free
Manager took ownership of logic
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=24b586c766ad7a674d962f2b131d5dec0674cc2e
---
modules/demux/adaptative/PlaylistManager.cpp | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/modules/demux/adaptative/PlaylistManager.cpp b/modules/demux/adaptative/PlaylistManager.cpp
index 129bf36..2091920 100644
--- a/modules/demux/adaptative/PlaylistManager.cpp
+++ b/modules/demux/adaptative/PlaylistManager.cpp
@@ -65,6 +65,7 @@ PlaylistManager::~PlaylistManager ()
unsetPeriod();
delete playlist;
delete conManager;
+ delete logic;
}
void PlaylistManager::unsetPeriod()
@@ -92,17 +93,13 @@ bool PlaylistManager::setupPeriod()
{
SegmentTracker *tracker = new (std::nothrow) SegmentTracker(logic, set);
if(!tracker)
- {
- delete logic;
continue;
- }
AbstractStream *st = streamFactory->create(p_demux, set->getStreamFormat(),
tracker, conManager);
if(!st)
{
delete tracker;
- delete logic;
continue;
}
More information about the vlc-commits
mailing list