diff options
author | Victoria Lease <violets@google.com> | 2012-11-07 13:55:58 -0800 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2012-11-07 13:56:46 -0800 |
commit | ad84f7f46b0207a7ad316b4df37c1f02c889cca9 (patch) | |
tree | 2e9ad10fb78ad22a63bcde8b9c732db3db5c31fe /services | |
parent | afc5210a811da3824d75e32d998370203aba1968 (diff) | |
parent | 56e675b3a1c351de34de68a149762d3ad1b308c5 (diff) | |
download | frameworks_base-ad84f7f46b0207a7ad316b4df37c1f02c889cca9.zip frameworks_base-ad84f7f46b0207a7ad316b4df37c1f02c889cca9.tar.gz frameworks_base-ad84f7f46b0207a7ad316b4df37c1f02c889cca9.tar.bz2 |
Merge "disable geofences for secondary users" into jb-mr1-dev
Diffstat (limited to 'services')
-rw-r--r-- | services/java/com/android/server/LocationManagerService.java | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/services/java/com/android/server/LocationManagerService.java b/services/java/com/android/server/LocationManagerService.java index 9416b52..2290505 100644 --- a/services/java/com/android/server/LocationManagerService.java +++ b/services/java/com/android/server/LocationManagerService.java @@ -1351,6 +1351,11 @@ public class LocationManagerService extends ILocationManager.Stub implements Run // geo-fence manager uses the public location API, need to clear identity int uid = Binder.getCallingUid(); + if (UserHandle.getUserId(uid) != UserHandle.USER_OWNER) { + // temporary measure until geofences work for secondary users + Log.w(TAG, "proximity alerts are currently available only to the primary user"); + return; + } long identity = Binder.clearCallingIdentity(); try { mGeofenceManager.addFence(sanitizedRequest, geofence, intent, uid, packageName); |