diff options
author | Scott Jackson <daneren2005@gmail.com> | 2015-10-20 09:15:59 -0700 |
---|---|---|
committer | Scott Jackson <daneren2005@gmail.com> | 2015-10-20 09:15:59 -0700 |
commit | 57e13e94620b837e4945858b6d7f3f1d4abf6941 (patch) | |
tree | 554ea84e71537a0e7170455deb2110d1149b48ea | |
parent | 1d312b4920c5c62425fcb4aedd7b5be4981f5fb7 (diff) | |
download | dsub-57e13e94620b837e4945858b6d7f3f1d4abf6941.tar.gz dsub-57e13e94620b837e4945858b6d7f3f1d4abf6941.tar.bz2 dsub-57e13e94620b837e4945858b6d7f3f1d4abf6941.zip |
Fix error on puase of EQ fragment if not able to grab a instance
-rw-r--r-- | app/src/main/java/github/daneren2005/dsub/fragments/EqualizerFragment.java | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/app/src/main/java/github/daneren2005/dsub/fragments/EqualizerFragment.java b/app/src/main/java/github/daneren2005/dsub/fragments/EqualizerFragment.java index e2535e04..6ca2da4f 100644 --- a/app/src/main/java/github/daneren2005/dsub/fragments/EqualizerFragment.java +++ b/app/src/main/java/github/daneren2005/dsub/fragments/EqualizerFragment.java @@ -112,10 +112,15 @@ public class EqualizerFragment extends SubsonicFragment { @Override public void onPause() { super.onPause(); - equalizerController.saveSettings(); - if(!equalizer.getEnabled()) { - equalizerController.release(); + try { + equalizerController.saveSettings(); + + if (!equalizer.getEnabled()) { + equalizerController.release(); + } + } catch(Exception e) { + Log.w(TAG, "Failed to release controller", e); } } |