From eb905b4e5f05cd67e4c6a82f11a9f54e27c2d06a Mon Sep 17 00:00:00 2001 From: wangdengjia Date: Tue, 7 Sep 2021 15:03:06 +0800 Subject: [PATCH] IssueNo:#I4908S Description:disable watch dog when transform bc file Sig:appexecfwk Feature or Bugfix:Bugfix Binary Source:No Signed-off-by: wangdengjia Change-Id: I8e4cb83de484e7484bc9fa81b9e973891e358789 Signed-off-by: wangdengjia --- .../bundlemgr_lite/src/gt_bundle_manager_service.cpp | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/services/bundlemgr_lite/src/gt_bundle_manager_service.cpp b/services/bundlemgr_lite/src/gt_bundle_manager_service.cpp index 9375e09..1c80064 100755 --- a/services/bundlemgr_lite/src/gt_bundle_manager_service.cpp +++ b/services/bundlemgr_lite/src/gt_bundle_manager_service.cpp @@ -732,7 +732,9 @@ void GtManagerService::TransformJsToBc(const char *codePath, const char *bundleJ return; } + DisableServiceWdg(); EXECRES result = walk_directory(jsPath); + EnableServiceWdg(); HILOG_INFO(HILOG_MODULE_AAFWK, "[BMS] transform js to bc, result is %d", result); if (result != EXCE_ACE_JERRY_EXEC_OK) { result = walk_del_bytecode(jsPath); @@ -760,7 +762,7 @@ void GtManagerService::TransformJsToBc(const char *codePath, const char *bundleJ return; } } - (void) BundleUtil::StoreJsonContentToFile(bundleJsonPath, installRecordObj); + (void)BundleUtil::StoreJsonContentToFile(bundleJsonPath, installRecordObj); } bool GtManagerService::CheckThirdSystemBundleHasUninstalled(const char *bundleName, const cJSON *object) @@ -975,7 +977,7 @@ void GtManagerService::APP_FreeAllAppInfo(const AppInfoList *list) AppInfoList *currentNode = nullptr; AppInfoList *nextNode = nullptr; - LOS_DL_LIST_FOR_EACH_ENTRY_SAFE (currentNode, nextNode, &list->appDoubleList, AppInfoList, appDoubleList) { + LOS_DL_LIST_FOR_EACH_ENTRY_SAFE(currentNode, nextNode, &list->appDoubleList, AppInfoList, appDoubleList) { if (currentNode != nullptr) { LOS_ListDelete(&(currentNode->appDoubleList)); AdapterFree(currentNode); @@ -1004,7 +1006,7 @@ void SetCurrentBundle(const char *name) } int len = strlen(name); - g_currentBundle = (char *) AdapterMalloc(len + 1); + g_currentBundle = (char *)AdapterMalloc(len + 1); if (g_currentBundle == nullptr || strncpy_s(g_currentBundle, len + 1, name, len) < 0) { AdapterFree(g_currentBundle); } @@ -1020,7 +1022,7 @@ const char *GetCurrentBundle() } int len = strlen(g_currentBundle); - char *bundleName = (char *) AdapterMalloc(len + 1); + char *bundleName = (char *)AdapterMalloc(len + 1); if (bundleName == nullptr || strncpy_s(bundleName, len + 1, g_currentBundle, len) < 0) { AdapterFree(bundleName); MutexRelease(&g_currentBundleMutex);