From 9770a3c402da1e09f3a5143f089173805edff32b Mon Sep 17 00:00:00 2001 From: Jeff Sharkey Date: Fri, 4 Oct 2013 16:41:10 -0700 Subject: Treat deleted in-progress downloads as canceled. Otherwise the download thread would keep going! Bug: 11081405 Change-Id: Ib8f1b624b29cabc782b8a0047d7b5db7e39a17de --- src/com/android/providers/downloads/DownloadThread.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/com/android') diff --git a/src/com/android/providers/downloads/DownloadThread.java b/src/com/android/providers/downloads/DownloadThread.java index def4d7fe..93f8d650 100644 --- a/src/com/android/providers/downloads/DownloadThread.java +++ b/src/com/android/providers/downloads/DownloadThread.java @@ -519,7 +519,7 @@ public class DownloadThread implements Runnable { throw new StopRequestException( Downloads.Impl.STATUS_PAUSED_BY_APP, "download paused by owner"); } - if (mInfo.mStatus == Downloads.Impl.STATUS_CANCELED) { + if (mInfo.mStatus == Downloads.Impl.STATUS_CANCELED || mInfo.mDeleted) { throw new StopRequestException(Downloads.Impl.STATUS_CANCELED, "download canceled"); } } -- cgit v1.2.3