summaryrefslogtreecommitdiffstats
path: root/media
diff options
context:
space:
mode:
authorEric Laurent <elaurent@google.com>2010-08-04 10:03:36 -0700
committerAndroid (Google) Code Review <android-gerrit@google.com>2010-08-04 10:03:36 -0700
commit610959a52fe22a88e50d158f5f5f492fee4f1921 (patch)
treeeadcbb991b13055cdee86dc3b482b8e8dce098d1 /media
parent48f6ce0e17297c575dcbb25671a7bee80ba13061 (diff)
parent3b26844e60f8487388e7e62709faf0dada86e7e1 (diff)
downloadframeworks_av-610959a52fe22a88e50d158f5f5f492fee4f1921.zip
frameworks_av-610959a52fe22a88e50d158f5f5f492fee4f1921.tar.gz
frameworks_av-610959a52fe22a88e50d158f5f5f492fee4f1921.tar.bz2
Merge "Fix issue 2876124." into gingerbread
Diffstat (limited to 'media')
-rw-r--r--media/libmedia/mediaplayer.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/media/libmedia/mediaplayer.cpp b/media/libmedia/mediaplayer.cpp
index 1c99ae5..f3229c0 100644
--- a/media/libmedia/mediaplayer.cpp
+++ b/media/libmedia/mediaplayer.cpp
@@ -568,7 +568,8 @@ void MediaPlayer::notify(int msg, int ext1, int ext2)
locked = true;
}
- if (mPlayer == 0) {
+ // Allows calls from JNI in idle state to notify errors
+ if (!(msg == MEDIA_ERROR && mCurrentState == MEDIA_PLAYER_IDLE) && mPlayer == 0) {
LOGV("notify(%d, %d, %d) callback on disconnected mediaplayer", msg, ext1, ext2);
if (locked) mLock.unlock(); // release the lock when done.
return;