Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8b38b29b authored by Victoria Lease's avatar Victoria Lease
Browse files

Notify provider when disposing last UpdateRecord

Location providers were not being notified of the change in status
when the last UpdateRecord was removed due to numUpdates exhaustion
or request expiry. Oops! Enjoy some free battery life!

Bug: 7611837
Change-Id: Id48151eb7de40164258cde7da220a4d6bb34b89a
parent 39ec1ec1
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -1711,6 +1711,10 @@ public class LocationManagerService extends ILocationManager.Stub implements Run
                r.disposeLocked(true);
            }
        }
        // let the provider know if we just disposed its last update record
        if (records.size() == 0) {
            applyRequirementsLocked(provider);
        }
    }

    private class LocationWorkerHandler extends Handler {