summaryrefslogtreecommitdiffstats
path: root/media
diff options
context:
space:
mode:
authorLajos Molnar <lajos@google.com>2014-12-11 16:21:42 +0000
committerAndroid Git Automerger <android-git-automerger@android.com>2014-12-11 16:21:42 +0000
commit9ae34ec4f2a78d98643cf8428cd8eafdc48e6245 (patch)
tree78102481db0da10e030e4a5212e9a5647d0c22e0 /media
parent11bfbc251e78486cd10fe891e27ae25b17285cb4 (diff)
parentb6ac4d49e468e155aa1591f3c400e1c06442e7b1 (diff)
downloadframeworks_av-9ae34ec4f2a78d98643cf8428cd8eafdc48e6245.zip
frameworks_av-9ae34ec4f2a78d98643cf8428cd8eafdc48e6245.tar.gz
frameworks_av-9ae34ec4f2a78d98643cf8428cd8eafdc48e6245.tar.bz2
am b6ac4d49: am 2253b3c5: am f484952e: mediaplayer: allow setVideoSurface before setDataSource
* commit 'b6ac4d49e468e155aa1591f3c400e1c06442e7b1': mediaplayer: allow setVideoSurface before setDataSource
Diffstat (limited to 'media')
-rw-r--r--media/libmediaplayerservice/nuplayer/NuPlayer.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/media/libmediaplayerservice/nuplayer/NuPlayer.cpp b/media/libmediaplayerservice/nuplayer/NuPlayer.cpp
index d433a4d..080cd52 100644
--- a/media/libmediaplayerservice/nuplayer/NuPlayer.cpp
+++ b/media/libmediaplayerservice/nuplayer/NuPlayer.cpp
@@ -537,7 +537,7 @@ void NuPlayer::onMessageReceived(const sp<AMessage> &msg) {
sp<RefBase> obj;
CHECK(msg->findObject("native-window", &obj));
- if (mSource->getFormat(false /* audio */) == NULL) {
+ if (mSource == NULL || mSource->getFormat(false /* audio */) == NULL) {
performSetSurface(static_cast<NativeWindowWrapper *>(obj.get()));
break;
}