diff options
author | 2012-09-18 23:33:20 -0700 | |
---|---|---|
committer | 2012-09-18 23:33:20 -0700 | |
commit | 3cdccc6f852be345c43bdfbc2466aa17c1173c9c (patch) | |
tree | de24959284e897fb91a937bc9f376147fa09ae8a | |
parent | 2398bc67bb04e9f087fd46455bf8ff1ce4eb510f (diff) | |
parent | a5b8e8bfa9f3416ce61ee08162fb139afde60488 (diff) |
Merge "fix a typo in SensorService" into jb-mr1-dev
-rw-r--r-- | services/sensorservice/SensorService.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/services/sensorservice/SensorService.cpp b/services/sensorservice/SensorService.cpp index 7ab34c9684..c9b0f7c27e 100644 --- a/services/sensorservice/SensorService.cpp +++ b/services/sensorservice/SensorService.cpp @@ -462,6 +462,9 @@ status_t SensorService::enable(const sp<SensorEventConnection>& connection, if (mActiveConnections.indexOf(connection) < 0) { mActiveConnections.add(connection); } + } else { + ALOGW("sensor %08x already enabled in connection %p (ignoring)", + handle, connection.get()); } } } @@ -567,7 +570,7 @@ void SensorService::SensorEventConnection::onFirstRef() bool SensorService::SensorEventConnection::addSensor(int32_t handle) { Mutex::Autolock _l(mConnectionLock); - if (mSensorInfo.indexOf(handle) <= 0) { + if (mSensorInfo.indexOf(handle) < 0) { mSensorInfo.add(handle); return true; } |