From 6646363eba7b14ccf36e0a4f2da73f530138fff7 Mon Sep 17 00:00:00 2001 From: Dario Casalinuovo Date: Tue, 17 May 2016 01:01:10 +0200 Subject: [PATCH] MediaExtractor: The source is always owned by BMediaFile * While originally I think it was a good idea to make it own the source, then I decided to uniform the code by making the BMediaFile to be the only responsible of that. --- src/kits/media/MediaExtractor.cpp | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/kits/media/MediaExtractor.cpp b/src/kits/media/MediaExtractor.cpp index e264977825..2847782179 100644 --- a/src/kits/media/MediaExtractor.cpp +++ b/src/kits/media/MediaExtractor.cpp @@ -184,12 +184,9 @@ MediaExtractor::~MediaExtractor() gPluginManager.DestroyReader(fReader); - // If this is a streaming situation we own - // the source - if (fStreamer != NULL) { - delete fSource; + if (fStreamer != NULL) gPluginManager.DestroyStreamer(fStreamer); - } + delete[] fStreamInfo; // fSource is owned by the BMediaFile }