diff options
author | daniel oeh <daniel.oeh@gmail.com> | 2012-09-10 16:35:44 +0200 |
---|---|---|
committer | daniel oeh <daniel.oeh@gmail.com> | 2012-09-10 16:35:44 +0200 |
commit | acce72d71bd635e30a32c940ce682dee6a807853 (patch) | |
tree | 05a9b7528b4b95e6c087d306094e154650ca5f26 /src/de/danoeh/antennapod | |
parent | bdb6e008aa29d5835fad42e233d9fe45a363369b (diff) | |
download | AntennaPod-acce72d71bd635e30a32c940ce682dee6a807853.zip |
Fixed NullPointerException in bindToService
Diffstat (limited to 'src/de/danoeh/antennapod')
-rw-r--r-- | src/de/danoeh/antennapod/service/PlaybackService.java | 2 | ||||
-rw-r--r-- | src/de/danoeh/antennapod/util/PlaybackController.java | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/de/danoeh/antennapod/service/PlaybackService.java b/src/de/danoeh/antennapod/service/PlaybackService.java index 65a2ae67d..19f5fed68 100644 --- a/src/de/danoeh/antennapod/service/PlaybackService.java +++ b/src/de/danoeh/antennapod/service/PlaybackService.java @@ -92,7 +92,7 @@ public class PlaybackService extends Service { public static final int NOTIFICATION_TYPE_BUFFER_END = 6; /** Is true if service is running. */ - public static boolean isRunning; + public static boolean isRunning = false; private static final int NOTIFICATION_ID = 1; private NotificationCompat.Builder notificationBuilder; diff --git a/src/de/danoeh/antennapod/util/PlaybackController.java b/src/de/danoeh/antennapod/util/PlaybackController.java index f43ca8d93..0253eba02 100644 --- a/src/de/danoeh/antennapod/util/PlaybackController.java +++ b/src/de/danoeh/antennapod/util/PlaybackController.java @@ -149,7 +149,7 @@ public abstract class PlaybackController { if (AppConfig.DEBUG) Log.d(TAG, "PlaybackService is running, trying to connect without start command."); - bound = activity.bindService(serviceIntent, mConnection, 0); + bound = activity.bindService(new Intent(activity, PlaybackService.class), mConnection, 0); } if (AppConfig.DEBUG) Log.d(TAG, "Result for service binding: " + bound); |