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

Commit c130d7ad authored by Greg Kaiser's avatar Greg Kaiser
Browse files

SensorService: Remove unused function

We remove the unused getSensorRecord function.  This function
was accessing the mActiveSensors field without obtaining a lock.
We're looking to simplify this code, so we just remove this instead
of trying to fix it.

Change-Id: I8c4ed3cc7ed17d90aa9a5d7f33f9ab9238f9403f
parent 90b745df
Loading
Loading
Loading
Loading
+0 −4
Original line number Diff line number Diff line
@@ -826,10 +826,6 @@ bool SensorService::isWakeUpSensorEvent(const sensors_event_t& event) const {
    return sensor != NULL && sensor->getSensor().isWakeUpSensor();
}

SensorService::SensorRecord * SensorService::getSensorRecord(int handle) {
     return mActiveSensors.valueFor(handle);
}

Vector<Sensor> SensorService::getSensorList(const String16& opPackageName) {
    char value[PROPERTY_VALUE_MAX];
    property_get("debug.sensors", value, "0");
+0 −2
Original line number Diff line number Diff line
@@ -184,8 +184,6 @@ private:
    bool isWakeUpSensorEvent(const sensors_event_t& event) const;
    bool isNewHandle(int handle);

    SensorRecord * getSensorRecord(int handle);

    sp<Looper> getLooper() const;

    // Reset mWakeLockRefCounts for all SensorEventConnections to zero. This may happen if