From 519e2371efd24590c4590acec065cba29b92052d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=BC=A0=E6=AC=A3=E5=AE=87?= Date: Mon, 1 Sep 2025 21:38:16 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8D=B8=E8=BD=BD=E6=8B=A6=E6=88=AA=E8=A7=84?= =?UTF-8?q?=E5=88=99=E5=8D=B8=E8=BD=BD=E5=AE=8C=E6=88=90=E5=90=8E=E5=86=8D?= =?UTF-8?q?=E5=88=A0=E9=99=A4-=E6=8C=91=E5=8D=955.1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: 张欣宇 Change-Id: I9932d9b4f45f32894e0cf6ac0539d111fdbc3f64 --- .../include/app_control/app_control_manager.h | 1 - .../bundlemgr/src/app_control/app_control_manager.cpp | 11 ----------- 2 files changed, 12 deletions(-) diff --git a/services/bundlemgr/include/app_control/app_control_manager.h b/services/bundlemgr/include/app_control/app_control_manager.h index 4ae002a755..b1cc21e90a 100644 --- a/services/bundlemgr/include/app_control/app_control_manager.h +++ b/services/bundlemgr/include/app_control/app_control_manager.h @@ -105,7 +105,6 @@ private: void KillRunningApp(const std::vector &rules, int32_t userId) const; void DeleteAppRunningRuleCache(std::string &key); void DeleteAbilityRunningRuleCache(std::string &key); - void DeleteAbilityRunningRuleBmsCache(const std::string &appId); bool CheckCanDispose(const std::string &appId, int32_t userId); void PrintDisposedRuleInfo(const std::vector &disposedRules); diff --git a/services/bundlemgr/src/app_control/app_control_manager.cpp b/services/bundlemgr/src/app_control/app_control_manager.cpp index 54dfec68d2..03fcd8590d 100644 --- a/services/bundlemgr/src/app_control/app_control_manager.cpp +++ b/services/bundlemgr/src/app_control/app_control_manager.cpp @@ -403,7 +403,6 @@ ErrCode AppControlManager::DeleteAllDisposedRuleByBundle(const InnerBundleInfo & LOG_E(BMS_TAG_DEFAULT, "DeleteAllDisposedRuleByBundle to rdb failed"); return ret; } - DeleteAbilityRunningRuleBmsCache(appId); std::string key = appId + std::string("_") + std::to_string(userId); DeleteAppRunningRuleCache(key); key = key + std::string("_"); @@ -543,16 +542,6 @@ void AppControlManager::DeleteDisposedRuleOnlyForBms(const std::string &appId) } } - -void AppControlManager::DeleteAbilityRunningRuleBmsCache(const std::string &appId) -{ - std::lock_guard cacheLock(abilityRunningControlRuleMutex_); - auto iterBms = abilityRunningControlRuleCacheForBms_.find(appId); - if (iterBms != abilityRunningControlRuleCacheForBms_.end()) { - abilityRunningControlRuleCacheForBms_.erase(iterBms); - } -} - ErrCode AppControlManager::SetUninstallDisposedRule(const std::string &callerName, const std::string &appIdentifier, const UninstallDisposedRule& rule, int32_t appIndex, int32_t userId) { -- Gitee