diff options
author | Robert Shih <robertshih@google.com> | 2014-10-30 17:22:11 -0700 |
---|---|---|
committer | Robert Shih <robertshih@google.com> | 2014-11-12 18:42:10 -0800 |
commit | bf20727f0aaf609bc3b495b07b45822b137d21ba (patch) | |
tree | 54dcd911084ba618a70907efc04da2970240a8da /media/libstagefright/httplive | |
parent | 701b96474dc8afd16046e440975e00be57cc4874 (diff) | |
download | frameworks_av-bf20727f0aaf609bc3b495b07b45822b137d21ba.zip frameworks_av-bf20727f0aaf609bc3b495b07b45822b137d21ba.tar.gz frameworks_av-bf20727f0aaf609bc3b495b07b45822b137d21ba.tar.bz2 |
PlaylistFetcher: check ts program streams before disabling a/v
Bug: 14648838
Change-Id: Ibf2b2cbb235f3d80bc33013e2afc053f13b9035f
Diffstat (limited to 'media/libstagefright/httplive')
-rw-r--r-- | media/libstagefright/httplive/PlaylistFetcher.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/media/libstagefright/httplive/PlaylistFetcher.cpp b/media/libstagefright/httplive/PlaylistFetcher.cpp index 30fa868..0d9ed96 100644 --- a/media/libstagefright/httplive/PlaylistFetcher.cpp +++ b/media/libstagefright/httplive/PlaylistFetcher.cpp @@ -963,8 +963,8 @@ void PlaylistFetcher::onDownloadNext() { } while (bytesRead != 0); if (bufferStartsWithTsSyncByte(buffer)) { - // If we still don't see a stream after fetching a full ts segment mark it as - // nonexistent. + // If we don't see a stream in the program table after fetching a full ts segment + // mark it as nonexistent. const size_t kNumTypes = ATSParser::NUM_SOURCE_TYPES; ATSParser::SourceType srcTypes[kNumTypes] = { ATSParser::VIDEO, ATSParser::AUDIO }; @@ -979,7 +979,7 @@ void PlaylistFetcher::onDownloadNext() { static_cast<AnotherPacketSource *>( mTSParser->getSource(srcType).get()); - if (source == NULL) { + if (!mTSParser->hasSource(srcType)) { ALOGW("MPEG2 Transport stream does not contain %s data.", srcType == ATSParser::VIDEO ? "video" : "audio"); |