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

Commit 01ed75c8 authored by Nick Pelly's avatar Nick Pelly
Browse files

Fix NPE when public API removeProximityAlert() used before addProximityAlert().

Bug: 6313992
Change-Id: I905ad9ea771286727ce4a3a2334f2a0dac967c3d
parent 059537e7
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -1702,7 +1702,9 @@ public class LocationManagerService extends ILocationManager.Stub implements Run

        mProximityAlerts.remove(intent);
        if (mProximityAlerts.size() == 0) {
            if (mProximityReceiver != null) {
                removeUpdatesLocked(mProximityReceiver);
            }
            mProximityReceiver = null;
            mProximityListener = null;
        }