Skip to content

Commit c2f1770

Browse files
Harikrishnan HariharanSteve Kondik
authored andcommitted
Prevent invocation of startNavigating() when GPS is off
When system comes back from idle state, GpsLocationProvider invokes startNavigating() even when GPS is turned off in settings. Change-Id: Ie6dbf60a743cce429ab83876a3cb80f7e4b0e0f6 CRs-Fixed: 1022372
1 parent 473970b commit c2f1770

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

services/core/java/com/android/server/location/GpsLocationProvider.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1118,7 +1118,7 @@ private void updateRequirements() {
11181118
}
11191119

11201120
if (DEBUG) Log.d(TAG, "setRequest " + mProviderRequest);
1121-
if (mProviderRequest.reportLocation && !mDisableGps) {
1121+
if (mProviderRequest.reportLocation && !mDisableGps && isEnabled()) {
11221122
// update client uids
11231123
updateClientUids(mWorkSource);
11241124

0 commit comments

Comments
 (0)