summaryrefslogtreecommitdiffstats
path: root/native
diff options
context:
space:
mode:
authorAravind Akella <aakella@google.com>2015-07-29 18:39:52 -0700
committerAravind Akella <aakella@google.com>2015-07-30 19:04:40 +0000
commit2af91d0e104b3a80f3e832e464e52893a55a715f (patch)
tree88af2f5c66cf2aab1989b9d14ff13110286c2e83 /native
parentf9dee58395fa72dc3764292aef4937dfcca0a14a (diff)
downloadframeworks_base-2af91d0e104b3a80f3e832e464e52893a55a715f.zip
frameworks_base-2af91d0e104b3a80f3e832e464e52893a55a715f.tar.gz
frameworks_base-2af91d0e104b3a80f3e832e464e52893a55a715f.tar.bz2
Call getInstanceForPackage instead of creating a new SensorManager instance.
Bug: 22529981 Change-Id: If077e042a4af940dfb1fc9c4ac8b9d352dd32685
Diffstat (limited to 'native')
-rw-r--r--native/android/sensor.cpp6
1 files changed, 1 insertions, 5 deletions
diff --git a/native/android/sensor.cpp b/native/android/sensor.cpp
index 26b41e8..76c701a 100644
--- a/native/android/sensor.cpp
+++ b/native/android/sensor.cpp
@@ -38,10 +38,6 @@ using android::String8;
using android::String16;
/*****************************************************************************/
-
-android::Mutex android::SensorManager::sLock;
-std::map<String16, SensorManager*> android::SensorManager::sPackageInstances;
-
ASensorManager* ASensorManager_getInstance()
{
return ASensorManager_getInstanceForPackage(NULL);
@@ -206,4 +202,4 @@ int ASensor_getReportingMode(ASensor const* sensor)
bool ASensor_isWakeUpSensor(ASensor const* sensor)
{
return static_cast<Sensor const*>(sensor)->isWakeUpSensor();
-} \ No newline at end of file
+}