diff options
author | Scott Jackson <daneren2005@gmail.com> | 2012-11-29 07:51:19 -0800 |
---|---|---|
committer | Scott Jackson <daneren2005@gmail.com> | 2012-11-29 07:51:19 -0800 |
commit | c87d2fe915e60b601c91f17f2dffb2f985cdf574 (patch) | |
tree | 64873e46686eb74207cdbf519ac76fd9c6268bed | |
parent | 29945f4f8421a13d2a87b004901c9b887e9d7387 (diff) | |
download | dsub-c87d2fe915e60b601c91f17f2dffb2f985cdf574.tar.gz dsub-c87d2fe915e60b601c91f17f2dffb2f985cdf574.tar.bz2 dsub-c87d2fe915e60b601c91f17f2dffb2f985cdf574.zip |
Fix null ptr exception
-rw-r--r-- | subsonic-android/src/github/daneren2005/dsub/activity/DownloadActivity.java | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/subsonic-android/src/github/daneren2005/dsub/activity/DownloadActivity.java b/subsonic-android/src/github/daneren2005/dsub/activity/DownloadActivity.java index 8d96499d..3fb87be1 100644 --- a/subsonic-android/src/github/daneren2005/dsub/activity/DownloadActivity.java +++ b/subsonic-android/src/github/daneren2005/dsub/activity/DownloadActivity.java @@ -540,10 +540,10 @@ public class DownloadActivity extends SubsonicTabActivity implements OnGestureLi else inflater.inflate(R.menu.nowplaying_downloading, menu); - if(getDownloadService().getSleepTimer()) { + if(getDownloadService() != null && getDownloadService().getSleepTimer()) { menu.findItem(R.id.menu_toggle_timer).setTitle(R.string.download_stop_timer); } - if(getDownloadService().getKeepScreenOn()) { + if(getDownloadService() != null && getDownloadService().getKeepScreenOn()) { menu.findItem(R.id.menu_screen_on_off).setTitle(R.string.download_menu_screen_off); } } |