diff --git a/headers/private/media/MediaExtractor.h b/headers/private/media/MediaExtractor.h index eeefca70bb..5f58b02d40 100644 --- a/headers/private/media/MediaExtractor.h +++ b/headers/private/media/MediaExtractor.h @@ -42,8 +42,6 @@ public: status_t InitCheck(); - BDataIO* Source() const; - void GetFileFormatInfo( media_file_format* fileFormat) const; status_t GetMetaData(BMessage* _data) const; diff --git a/src/kits/media/MediaExtractor.cpp b/src/kits/media/MediaExtractor.cpp index 1241e76152..058f6afeb0 100644 --- a/src/kits/media/MediaExtractor.cpp +++ b/src/kits/media/MediaExtractor.cpp @@ -173,13 +173,6 @@ MediaExtractor::InitCheck() } -BDataIO* -MediaExtractor::Source() const -{ - return fSource; -} - - void MediaExtractor::GetFileFormatInfo(media_file_format* fileFormat) const { diff --git a/src/kits/media/MediaFile.cpp b/src/kits/media/MediaFile.cpp index ffde93f9d2..0a6ba56b06 100644 --- a/src/kits/media/MediaFile.cpp +++ b/src/kits/media/MediaFile.cpp @@ -479,9 +479,9 @@ BMediaFile::_UnInit() if (fDeleteSource) { delete fSource; - fSource = NULL; fDeleteSource = false; } + fSource = NULL; // Deleting the extractor or writer can cause unloading of the plugins. // The source must be deleted before that, because it can come from a @@ -523,8 +523,7 @@ BMediaFile::_InitReader(BDataIO* source, const BUrl* url, int32 flags) if (fErr != B_OK) return; - // Get the actual source from the extractor - fSource = fExtractor->Source(); + fSource = source; fExtractor->GetFileFormatInfo(&fMFI); fTrackNum = fExtractor->StreamCount();