Fixed crash in download service

This commit is contained in:
ByteHamster 2019-11-24 19:57:56 +01:00
parent 66c91f9962
commit 4bda044472
1 changed files with 3 additions and 1 deletions

View File

@ -217,7 +217,9 @@ public class DownloadService extends Service {
syncExecutor.shutdown();
schedExecutor.shutdown();
cancelNotificationUpdater();
downloadPostFuture.cancel(true);
if (downloadPostFuture != null) {
downloadPostFuture.cancel(true);
}
unregisterReceiver(cancelDownloadReceiver);
// if this was the initial gpodder sync, i.e. we just synced the feeds successfully,