From e613fee91ad72c9736363aba3a16aa5be9cacedc Mon Sep 17 00:00:00 2001 From: dy_study Date: Thu, 28 Apr 2022 14:50:58 +0800 Subject: [PATCH] fix bm crash Signed-off-by: dy_study --- .../include/bundlemgr/bundle_mgr_interface.h | 49 ++++++++++--------- 1 file changed, 25 insertions(+), 24 deletions(-) diff --git a/interfaces/innerkits/appexecfwk_core/include/bundlemgr/bundle_mgr_interface.h b/interfaces/innerkits/appexecfwk_core/include/bundlemgr/bundle_mgr_interface.h index 96a440b1..68b20d19 100644 --- a/interfaces/innerkits/appexecfwk_core/include/bundlemgr/bundle_mgr_interface.h +++ b/interfaces/innerkits/appexecfwk_core/include/bundlemgr/bundle_mgr_interface.h @@ -598,6 +598,31 @@ public: { return false; } + + /** + * @brief Obtains the value of isRemovable based on a given bundle name and module name. + * @param bundleName Indicates the bundle name to be queried. + * @param moduleName Indicates the module name to be queried. + * @return Returns true if the isRemovable is successfully obtained; returns false otherwise. + */ + virtual bool IsModuleRemovable(const std::string &bundleName, const std::string &moduleName) + { + return false; + } + /** + * @brief Sets whether to enable isRemovable based on a given bundle name and module name. + * @param bundleName Indicates the bundle name to be queried. + * @param moduleName Indicates the module name to be queried. + * @param isEnable Specifies whether to enable the isRemovable of InnerModuleInfo. + * The value true means to enable it, and the value false means to disable it + * @return Returns true if the isRemovable is successfully obtained; returns false otherwise. + */ + virtual bool SetModuleRemovable( + const std::string &bundleName, const std::string &moduleName, bool isEnable) + { + return false; + } + /** * @brief Dump the bundle informations with specific flags. * @param flag Indicates the information contained in the dump result. @@ -966,30 +991,6 @@ public: return false; } - /** - * @brief Obtains the value of isRemovable based on a given bundle name and module name. - * @param bundleName Indicates the bundle name to be queried. - * @param moduleName Indicates the module name to be queried. - * @return Returns true if the isRemovable is successfully obtained; returns false otherwise. - */ - virtual bool IsModuleRemovable(const std::string &bundleName, const std::string &moduleName) - { - return false; - } - /** - * @brief Sets whether to enable isRemovable based on a given bundle name and module name. - * @param bundleName Indicates the bundle name to be queried. - * @param moduleName Indicates the module name to be queried. - * @param isEnable Specifies whether to enable the isRemovable of InnerModuleInfo. - * The value true means to enable it, and the value false means to disable it - * @return Returns true if the isRemovable is successfully obtained; returns false otherwise. - */ - virtual bool SetModuleRemovable( - const std::string &bundleName, const std::string &moduleName, bool isEnable) - { - return false; - } - /** * @brief Obtains the dependent module names. *