Skip to content
Commit 6d3455e4 authored by Hall Liu's avatar Hall Liu Committed by Rambo Wang
Browse files

Make LocationAccessQuery's builder safer to use

Add new methods on LocationAccessQuery.Builder to make it harder to
screw up when using. Changes include:
* Mandatory specification of min sdk levels for enforcing both fine and
coarse permission
* Mandatory "are-you-sure" check when both fine and coarse are above the
base level (i.e. when there are api levels that are left unprotected)

Also adapt TelephonyRegistry's permission checks to follow these new
requirements on the builder.

Fixes: 157170257
Test: CTS, unit tests, manual
Merged-In: Ica8779dff4c671352b917a3ccc02cdd0e1c5856d
Change-Id: Ica8779dff4c671352b917a3ccc02cdd0e1c5856d
(cherry picked from commit d7c23516)
parent b9680bac
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment