diff options
author | Jay Shrauner <shrauner@google.com> | 2015-10-13 00:00:03 +0000 |
---|---|---|
committer | Android Git Automerger <android-git-automerger@android.com> | 2015-10-13 00:00:03 +0000 |
commit | 01b435b5efd591a615378251c672d44840c808be (patch) | |
tree | 55426935945a7111fee0d3ec995cbce69ac4f58a | |
parent | ebca0a7459356de75778672288a6a486939e3d3a (diff) | |
parent | 8aa09c8771ef5d521c3f646484d9304a19cf6fd9 (diff) |
am 8aa09c87: Fix NPE in requestContent
* commit '8aa09c8771ef5d521c3f646484d9304a19cf6fd9':
Fix NPE in requestContent
-rw-r--r-- | src/com/android/dialer/voicemail/VoicemailPlaybackPresenter.java | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/com/android/dialer/voicemail/VoicemailPlaybackPresenter.java b/src/com/android/dialer/voicemail/VoicemailPlaybackPresenter.java index 8b8b7c539..9b4e20d38 100644 --- a/src/com/android/dialer/voicemail/VoicemailPlaybackPresenter.java +++ b/src/com/android/dialer/voicemail/VoicemailPlaybackPresenter.java @@ -625,7 +625,7 @@ public class VoicemailPlaybackPresenter implements MediaPlayer.OnPreparedListene * playing. */ public void resumePlayback() { - if (mView == null) { + if (mView == null || mContext == null) { return; } @@ -638,7 +638,7 @@ public class VoicemailPlaybackPresenter implements MediaPlayer.OnPreparedListene mIsPlaying = true; - if (!mMediaPlayer.isPlaying()) { + if (mMediaPlayer != null && !mMediaPlayer.isPlaying()) { // Clamp the start position between 0 and the duration. mPosition = Math.max(0, Math.min(mPosition, mDuration.get())); |