diff options
author | Robert Shih <robertshih@google.com> | 2014-09-18 00:55:01 +0000 |
---|---|---|
committer | Android Git Automerger <android-git-automerger@android.com> | 2014-09-18 00:55:01 +0000 |
commit | 6f6b3a8601fca2aa09acb83aaa1b52fdbde702e9 (patch) | |
tree | 6e208d011a6a2751561b52f51d7a3098c50434dc /media | |
parent | 2aa89ebb49c5f2b04e21a69e82b93166dbc34cf8 (diff) | |
parent | 2973994af39d55b58728df3dca067594e826ea2a (diff) | |
download | frameworks_av-6f6b3a8601fca2aa09acb83aaa1b52fdbde702e9.zip frameworks_av-6f6b3a8601fca2aa09acb83aaa1b52fdbde702e9.tar.gz frameworks_av-6f6b3a8601fca2aa09acb83aaa1b52fdbde702e9.tar.bz2 |
am 2973994a: Merge "PlaylistFetcher:don\'t signal a/v eos on subttitle eos" into lmp-dev
* commit '2973994af39d55b58728df3dca067594e826ea2a':
PlaylistFetcher:don't signal a/v eos on subttitle eos
Diffstat (limited to 'media')
-rw-r--r-- | media/libstagefright/httplive/LiveSession.cpp | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/media/libstagefright/httplive/LiveSession.cpp b/media/libstagefright/httplive/LiveSession.cpp index 7786c27..b465566 100644 --- a/media/libstagefright/httplive/LiveSession.cpp +++ b/media/libstagefright/httplive/LiveSession.cpp @@ -443,6 +443,23 @@ void LiveSession::onMessageReceived(const sp<AMessage> &msg) { ALOGE("XXX Received error %d from PlaylistFetcher.", err); + // handle EOS on subtitle tracks independently + AString uri; + if (err == ERROR_END_OF_STREAM && msg->findString("uri", &uri)) { + ssize_t i = mFetcherInfos.indexOfKey(uri); + if (i >= 0) { + const sp<PlaylistFetcher> &fetcher = mFetcherInfos.valueAt(i).mFetcher; + if (fetcher != NULL) { + uint32_t type = fetcher->getStreamTypeMask(); + if (type == STREAMTYPE_SUBTITLES) { + mPacketSources.valueFor( + STREAMTYPE_SUBTITLES)->signalEOS(err);; + break; + } + } + } + } + if (mInPreparationPhase) { postPrepared(err); } |