aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorScott Jackson <daneren2005@gmail.com>2015-02-15 18:39:20 -0800
committerScott Jackson <daneren2005@gmail.com>2015-02-15 18:39:20 -0800
commitfefed981cd39a650bd0de515d5327c4c0fa2715e (patch)
tree871117aaf3b84681af1de393c16d681a6c8c3d99 /src
parent8cf93e50054f766a216d32173eef0e457a3b1b50 (diff)
downloaddsub-fefed981cd39a650bd0de515d5327c4c0fa2715e.tar.gz
dsub-fefed981cd39a650bd0de515d5327c4c0fa2715e.tar.bz2
dsub-fefed981cd39a650bd0de515d5327c4c0fa2715e.zip
Fix a random crash with casting to ChromeCast
Diffstat (limited to 'src')
-rw-r--r--src/github/daneren2005/dsub/service/DownloadService.java4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/github/daneren2005/dsub/service/DownloadService.java b/src/github/daneren2005/dsub/service/DownloadService.java
index 473815dc..8c6016ba 100644
--- a/src/github/daneren2005/dsub/service/DownloadService.java
+++ b/src/github/daneren2005/dsub/service/DownloadService.java
@@ -1941,6 +1941,10 @@ public class DownloadService extends Service {
postPlayCleanup(currentPlaying);
}
public void postPlayCleanup(DownloadFile downloadFile) {
+ if(downloadFile == null) {
+ return;
+ }
+
// Finished loading, delete when list is cleared
if (downloadFile.getSong() instanceof PodcastEpisode) {
toDelete.add(downloadFile);