From 73939a628b33c38bdcde6c6dedd4f756691c0d2a Mon Sep 17 00:00:00 2001 From: akirilov Date: Fri, 19 Oct 2018 10:11:36 -0700 Subject: Fix CTS regression caused by ag/4690195 Bug: 111085900 Bug: 116183274 Test: run cts -m CtsAppTestCases -t android.app.cts.DownloadManagerTest#testDownloadManager android.app.cts.DownloadManagerTest#testDownloadManagerDestination android.app.cts.DownloadManagerTest#testDownloadManagerDestinationExtension android.app.cts.DownloadManagerTest#testDownloadManagerSupportsHttp android.app.cts.DownloadManagerTest#testDownloadManagerSupportsHttpWithExternalWebServer android.app.cts.DownloadManagerTest#testDownloadManagerSupportsHttpsWithExternalWebServer android.app.cts.DownloadManagerTest#testMinimumDownload Change-Id: I5c4ec97c5c4aa76bf9e0bbb352a470f230750bd9 --- src/com/android/providers/downloads/DownloadProvider.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/com/android/providers/downloads/DownloadProvider.java b/src/com/android/providers/downloads/DownloadProvider.java index e8240782..4a0252b4 100644 --- a/src/com/android/providers/downloads/DownloadProvider.java +++ b/src/com/android/providers/downloads/DownloadProvider.java @@ -1235,7 +1235,9 @@ public final class DownloadProvider extends ContentProvider { case ALL_DOWNLOADS: case ALL_DOWNLOADS_ID: final SQLiteQueryBuilder qb = getQueryBuilder(uri, match); - try (Cursor cursor = qb.query(db, null, where, whereArgs, null, null, null)) { + try (Cursor cursor = qb.query(db, new String[] { + _ID, _DATA, COLUMN_MEDIAPROVIDER_URI + }, where, whereArgs, null, null, null)) { while (cursor.moveToNext()) { final long id = cursor.getLong(0); scheduler.cancel((int) id); -- cgit v1.2.3