summaryrefslogtreecommitdiffstats
path: root/media
diff options
context:
space:
mode:
authorWei Jia <wjia@google.com>2016-08-30 13:49:06 -0700
committergitbuildkicker <android-build@google.com>2016-08-30 18:05:24 -0700
commit4b459da1ee3bb52ddfcc649dc2686975a9d72ab7 (patch)
treebfb72c09b0bed862a583cf7ac3d593d35613e625 /media
parent45f500ac36958b36afa649c8d68490cd38442252 (diff)
downloadframeworks_av-4b459da1ee3bb52ddfcc649dc2686975a9d72ab7.zip
frameworks_av-4b459da1ee3bb52ddfcc649dc2686975a9d72ab7.tar.gz
frameworks_av-4b459da1ee3bb52ddfcc649dc2686975a9d72ab7.tar.bz2
MediaPlayerService: allow next player to be NULL
Bug: 31155917 Bug: 30204103 Change-Id: I9a2a59ddb900fc942e7c19b31b53a110d790474c (cherry picked from commit 282841278723166e74039329ca56e444ad472daf)
Diffstat (limited to 'media')
-rw-r--r--media/libmediaplayerservice/MediaPlayerService.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/media/libmediaplayerservice/MediaPlayerService.cpp b/media/libmediaplayerservice/MediaPlayerService.cpp
index 0483228..f802de1 100644
--- a/media/libmediaplayerservice/MediaPlayerService.cpp
+++ b/media/libmediaplayerservice/MediaPlayerService.cpp
@@ -1062,7 +1062,7 @@ status_t MediaPlayerService::Client::setNextPlayer(const sp<IMediaPlayer>& playe
ALOGV("setNextPlayer");
Mutex::Autolock l(mLock);
sp<Client> c = static_cast<Client*>(player.get());
- if (!mService->hasClient(c)) {
+ if (c != NULL && !mService->hasClient(c)) {
return BAD_VALUE;
}