diff options
author | Jeff Sharkey <jsharkey@android.com> | 2017-10-24 16:54:54 -0600 |
---|---|---|
committer | Jeff Sharkey <jsharkey@android.com> | 2017-10-25 11:25:38 -0600 |
commit | d52fa66c75da2055bbe1b92b2e31b0342251002f (patch) | |
tree | 5c6f984119cba3d630b67e897f258e97d1309a8d /src/com/android/providers/downloads/DownloadThread.java | |
parent | 5872a1d7e2f6298f5bd3f411dc3c1d283fbd7508 (diff) | |
download | android_packages_providers_DownloadProvider-d52fa66c75da2055bbe1b92b2e31b0342251002f.tar.gz android_packages_providers_DownloadProvider-d52fa66c75da2055bbe1b92b2e31b0342251002f.tar.bz2 android_packages_providers_DownloadProvider-d52fa66c75da2055bbe1b92b2e31b0342251002f.zip |
Use explicit Network from JobParameters.
On devices with multiple active networks, or rapidly switching
between networks, we need an API to tell jobs explicitly which
network to use. (For example, the default route could meet all
job criteria, but we could have changed the default network by the
time we spun up the JobService.)
Test: verified via DownloadManager
Bug: 64133169
Change-Id: I9c131818d7199f79e147893d85c281473d00bee9
Diffstat (limited to 'src/com/android/providers/downloads/DownloadThread.java')
-rw-r--r-- | src/com/android/providers/downloads/DownloadThread.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/com/android/providers/downloads/DownloadThread.java b/src/com/android/providers/downloads/DownloadThread.java index 1476f4a0..984d2fcd 100644 --- a/src/com/android/providers/downloads/DownloadThread.java +++ b/src/com/android/providers/downloads/DownloadThread.java @@ -285,7 +285,7 @@ public class DownloadThread extends Thread { // Use the caller's default network to make this connection, since // they might be subject to restrictions that we shouldn't let them // circumvent - mNetwork = mSystemFacade.getActiveNetwork(mInfo.mUid, mIgnoreBlocked); + mNetwork = mSystemFacade.getNetwork(mParams); if (mNetwork == null) { throw new StopRequestException(STATUS_WAITING_FOR_NETWORK, "No network associated with requesting UID"); |