diff options
author | 2021-01-22 17:27:07 +0000 | |
---|---|---|
committer | 2021-02-02 20:25:47 +0000 | |
commit | d8b153b7c2026f45db97a7fd5804957becc5cfdf (patch) | |
tree | 014e91484c13e2c44cfa1380f388c758b7c23c0c /runtime/hidden_api.cc | |
parent | b1cf83748ce8165fe7e41ce6a57eb5529946a971 (diff) |
Remove obsolete TestApiEnforcementPolicy.
Access to TestApis is now gated by @ChangeId ALLOW_TEST_API_ACCESS.
Bug: 147113465
Test: presubmit
Change-Id: I4c5e336069bce3bccfcde0bcd84b6c1f539635e9
Diffstat (limited to 'runtime/hidden_api.cc')
-rw-r--r-- | runtime/hidden_api.cc | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/runtime/hidden_api.cc b/runtime/hidden_api.cc index f4f46eec96..1ad59ff08d 100644 --- a/runtime/hidden_api.cc +++ b/runtime/hidden_api.cc @@ -496,13 +496,9 @@ bool ShouldDenyAccessToMemberImpl(T* member, ApiList api_list, AccessMethod acce return false; } - EnforcementPolicy testApiPolicy = runtime->GetTestApiEnforcementPolicy(); - bool deny_access = false; if (hiddenApiPolicy == EnforcementPolicy::kEnabled) { - if (api_list.IsTestApi() && - (testApiPolicy == EnforcementPolicy::kDisabled || - compatFramework.IsChangeEnabled(kAllowTestApiAccess))) { + if (api_list.IsTestApi() && compatFramework.IsChangeEnabled(kAllowTestApiAccess)) { deny_access = false; } else { switch (api_list.GetMaxAllowedSdkVersion()) { |