summaryrefslogtreecommitdiff
path: root/src/de
diff options
context:
space:
mode:
authordaniel oeh <daniel.oeh@gmail.com>2012-08-11 23:54:15 +0200
committerdaniel oeh <daniel.oeh@gmail.com>2012-08-11 23:54:15 +0200
commit099dd9302710b6233915a0a01fa1d0820534c794 (patch)
tree7e5b1e325b8a1199c517d6919dc1306e84dbdde8 /src/de
parent69c3d2a589e34a03568bdcf9e02fb5d1d7878d4b (diff)
downloadAntennaPod-099dd9302710b6233915a0a01fa1d0820534c794.zip
Fixed possible nullpointer exception
Diffstat (limited to 'src/de')
-rw-r--r--src/de/danoeh/antennapod/activity/MediaplayerActivity.java9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/de/danoeh/antennapod/activity/MediaplayerActivity.java b/src/de/danoeh/antennapod/activity/MediaplayerActivity.java
index f6157a544..d8c9c02b9 100644
--- a/src/de/danoeh/antennapod/activity/MediaplayerActivity.java
+++ b/src/de/danoeh/antennapod/activity/MediaplayerActivity.java
@@ -121,8 +121,13 @@ public abstract class MediaplayerActivity extends SherlockFragmentActivity
public void onReceive(Context context, Intent intent) {
if (AppConfig.DEBUG)
Log.d(TAG, "Received statusUpdate Intent.");
- status = playbackService.getStatus();
- handleStatus();
+ if (playbackService != null) {
+ status = playbackService.getStatus();
+ handleStatus();
+ } else {
+ Log.w(TAG,
+ "Couldn't receive status update: playbackService was null");
+ }
}
};