diff options
author | Marco Nelissen <marcone@google.com> | 2010-03-10 10:53:16 -0800 |
---|---|---|
committer | Marco Nelissen <marcone@google.com> | 2010-03-10 10:55:09 -0800 |
commit | e44b41badac8014ec4447aef4d1ef23464f4555c (patch) | |
tree | 0ab3fbcdadb31703f1962887b4a8c799a50012ce /media/libmedia | |
parent | a8fbe1fb74d3bd40b73c90c85ac25e5176475ca5 (diff) | |
download | frameworks_base-e44b41badac8014ec4447aef4d1ef23464f4555c.zip frameworks_base-e44b41badac8014ec4447aef4d1ef23464f4555c.tar.gz frameworks_base-e44b41badac8014ec4447aef4d1ef23464f4555c.tar.bz2 |
MEDIA_PLAYER_STATE_ERROR is not a bitmask
(b/2502881)
Change-Id: I08e427eb2c36f5d70e40f9aeb8638fa8262de989
Diffstat (limited to 'media/libmedia')
-rw-r--r-- | media/libmedia/mediaplayer.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/media/libmedia/mediaplayer.cpp b/media/libmedia/mediaplayer.cpp index d2cec0c..f623295 100644 --- a/media/libmedia/mediaplayer.cpp +++ b/media/libmedia/mediaplayer.cpp @@ -104,7 +104,8 @@ status_t MediaPlayer::setDataSource(const sp<IMediaPlayer>& player) { // scope for the lock Mutex::Autolock _l(mLock); - if ( !( mCurrentState & ( MEDIA_PLAYER_IDLE | MEDIA_PLAYER_STATE_ERROR ) ) ) { + if ( !( (mCurrentState & MEDIA_PLAYER_IDLE) || + (mCurrentState == MEDIA_PLAYER_STATE_ERROR ) ) ) { LOGE("setDataSource called in state %d", mCurrentState); return INVALID_OPERATION; } |