commit | 91ea571836401ba77854d7b3aefb3ccee9c20eb3 | [log] [tgz] |
---|---|---|
author | Robert Shih <robertshih@google.com> | Mon Aug 01 16:26:58 2016 -0700 |
committer | Robert Shih <robertshih@google.com> | Mon Aug 01 18:12:29 2016 -0700 |
tree | 83967577c94c99f12569855d0b019c0f90c9a337 | |
parent | 3a7867c09fcbbcee32df9fa693a30cc65dc95887 [diff] |
rtsp: fix StopBuffering condition in monitor Stop buffering once there is sufficient data on all tracks. Bug: 30230942 Change-Id: Iae484a4aab720c0bd70e0c122fd87e8237156019
diff --git a/media/libmediaplayerservice/nuplayer/RTSPSource.cpp b/media/libmediaplayerservice/nuplayer/RTSPSource.cpp index 8a305de..901f636 100644 --- a/media/libmediaplayerservice/nuplayer/RTSPSource.cpp +++ b/media/libmediaplayerservice/nuplayer/RTSPSource.cpp
@@ -369,8 +369,11 @@ startBufferingIfNecessary(); } - if (overflow && mHandler != NULL) { + if (haveSufficientDataOnAllTracks()) { stopBufferingIfNecessary(); + } + + if (overflow && mHandler != NULL) { mHandler->pause(); }