summaryrefslogtreecommitdiffstats
path: root/services
diff options
context:
space:
mode:
Diffstat (limited to 'services')
-rw-r--r--services/core/java/com/android/server/location/GpsLocationProvider.java4
1 files changed, 1 insertions, 3 deletions
diff --git a/services/core/java/com/android/server/location/GpsLocationProvider.java b/services/core/java/com/android/server/location/GpsLocationProvider.java
index 2a1f7d6..af2da89 100644
--- a/services/core/java/com/android/server/location/GpsLocationProvider.java
+++ b/services/core/java/com/android/server/location/GpsLocationProvider.java
@@ -788,9 +788,7 @@ public class GpsLocationProvider implements LocationProviderInterface {
}
if (info != null) {
- boolean dataEnabled = TelephonyManager.getIntWithSubId(mContext.getContentResolver(),
- Settings.Global.MOBILE_DATA, SubscriptionManager.getDefaultSubId(),
- 1) == 1;
+ boolean dataEnabled = TelephonyManager.getDefault().getDataEnabled();
boolean networkAvailable = info.isAvailable() && dataEnabled;
String defaultApn = getSelectedApn();
if (defaultApn == null) {