mirror of
https://github.com/openharmony/bundlemanager_bundle_framework_lite.git
synced 2026-07-19 12:13:04 -04:00
@@ -207,7 +207,7 @@ bool AbilityInfoUtils::SetAbilityInfoSkill(AbilityInfo *abilityInfo, Skill * con
|
||||
if (skills[i] == nullptr) {
|
||||
return false;
|
||||
}
|
||||
abilityInfo->skills[i] = (Skill *)AdapterMalloc(sizeof(Skill));
|
||||
abilityInfo->skills[i] = static_cast<Skill *>(AdapterMalloc(sizeof(Skill)));
|
||||
CopyStringArray(abilityInfo->skills[i]->entities, skills[i]->entities, MAX_SKILL_ITEM);
|
||||
CopyStringArray(abilityInfo->skills[i]->actions, skills[i]->actions, MAX_SKILL_ITEM);
|
||||
}
|
||||
|
||||
@@ -350,8 +350,8 @@ bool GtManagerService::MatchSkills(const Want *want, Skill *const skills[])
|
||||
}
|
||||
bool GtManagerService::isMatchActions(const char *actions, char *const skillActions[])
|
||||
{
|
||||
if (actions == nullptr && skillActions == nullptr) {
|
||||
return true;
|
||||
if (actions == nullptr || skillActions == nullptr) {
|
||||
return false;
|
||||
}
|
||||
for (int32_t i = 0; i < MAX_SKILL_ITEM; i++) {
|
||||
if (skillActions[i] == nullptr) {
|
||||
@@ -953,6 +953,9 @@ void GtManagerService::TransformJsToBcWhenRestart(const char *codePath, const ch
|
||||
}
|
||||
|
||||
cJSON *oldJsEngineVerObj = cJSON_GetObjectItem(installRecordJson, JSON_SUB_KEY_JSENGINE_VERSION);
|
||||
if (oldJsEngineVerObj == nullptr) {
|
||||
return;
|
||||
}
|
||||
if (cJSON_IsString(oldJsEngineVerObj) && strcmp(oldJsEngineVerObj->valuestring, jsEngineVer_) == 0) {
|
||||
cJSON_Delete(jsEngineVerObj);
|
||||
cJSON *transformResultObj = cJSON_GetObjectItem(installRecordJson, JSON_SUB_KEY_TRANSFORM_RESULT);
|
||||
|
||||
Reference in New Issue
Block a user