From 0d70ca1126822ff25e01403240d48d40e666183a Mon Sep 17 00:00:00 2001 From: zhangkun Date: Tue, 20 Jan 2026 18:12:27 +0800 Subject: [PATCH] fix: set DSG_APP_ID to prevent self-identification deadlock MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Set the DSG_APP_ID environment variable to ApplicationManagerConfig before initializing the application. This prevents the application manager from calling its own Identify interface when accessing its own dconfig, which would cause a deadlock. Log: Fixed a potential deadlock issue when the application manager accesses its own configuration Influence: 1. Test application manager startup and initialization 2. Verify that the application manager can read its own dconfig without hanging 3. Test interaction with other DSG applications to ensure environment variable doesn't interfere 4. Monitor system logs for any identification-related errors during startup fix: 设置DSG_APP_ID环境变量防止自身识别死锁 在应用程序初始化之前设置DSG_APP_ID环境变量为ApplicationManagerConfig。这 可以防止应用程序管理器在访问自身dconfig时调用自己的Identify接口,从而避 免死锁发生。 Log: 修复了应用程序管理器访问自身配置时可能出现的死锁问题 Influence: 1. 测试应用程序管理器的启动和初始化过程 2. 验证应用程序管理器能够正常读取自身dconfig而不出现挂起 3. 测试与其他DSG应用程序的交互,确保环境变量设置不会产生干扰 4. 监控系统日志,检查启动过程中是否有识别相关的错误 PMS: BUG-345379 --- apps/dde-application-manager/src/main.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/apps/dde-application-manager/src/main.cpp b/apps/dde-application-manager/src/main.cpp index 70f1b58c..c9f567ab 100644 --- a/apps/dde-application-manager/src/main.cpp +++ b/apps/dde-application-manager/src/main.cpp @@ -37,6 +37,7 @@ void registerComplexDbusType() int main(int argc, char *argv[]) { + qputenv("DSG_APP_ID", ApplicationManagerConfig); #ifdef PROFILING_MODE auto start = std::chrono::high_resolution_clock::now(); #endif