Android: quick fix from a bug report from the market in the download manager
authorXeli
Mon, 16 Jan 2012 14:25:26 +0100
changeset 6587 3a0b9257c4f9
parent 6586 51d5dd5464aa
child 6588 58c04b8c6aee
Android: quick fix from a bug report from the market in the download manager
project_files/Android-build/SDL-android-project/src/org/hedgewars/hedgeroid/Downloader/DownloadService.java
--- a/project_files/Android-build/SDL-android-project/src/org/hedgewars/hedgeroid/Downloader/DownloadService.java	Wed Jan 18 01:11:09 2012 +0100
+++ b/project_files/Android-build/SDL-android-project/src/org/hedgewars/hedgeroid/Downloader/DownloadService.java	Mon Jan 16 14:25:26 2012 +0100
@@ -87,7 +87,7 @@
 					if(task != null && task.getPackage().equals(pack) && task.getStatus() == TASK_STATE.PENDING){
 						downloadTasks.remove(task);
 					}
-					if(currentTask.getPackage().equals(pack)){
+					if(currentTask != null && currentTask.getPackage().equals(pack)){//TODO synchronization problem?
 						asyncExecutor.cancel(false);
 					}
 					return;