mirror of
https://gitee.com/openharmony/bundlemanager_bundle_framework
synced 2024-11-23 07:09:53 +00:00
!7055 AddPermissionUsedRecord增加返回值校验
Merge pull request !7055 from xuyicong/fix_addpermissionusedrecord
This commit is contained in:
commit
253d21d355
@ -587,7 +587,11 @@ void BundlePermissionMgr::AddPermissionUsedRecord(
|
||||
AccessToken::AccessTokenID callerToken = IPCSkeleton::GetCallingTokenID();
|
||||
AccessToken::ATokenTypeEnum tokenType = AccessToken::AccessTokenKit::GetTokenTypeFlag(callerToken);
|
||||
if (tokenType == AccessToken::ATokenTypeEnum::TOKEN_HAP) {
|
||||
AccessToken::PrivacyKit::AddPermissionUsedRecord(callerToken, permission, successCount, failCount);
|
||||
int32_t ret = AccessToken::PrivacyKit::AddPermissionUsedRecord(callerToken, permission,
|
||||
successCount, failCount);
|
||||
if (ret != AccessToken::AccessTokenKitRet::RET_SUCCESS) {
|
||||
APP_LOGE("AddPermissionUsedRecord failed, ret = %{public}d", ret);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user