From c7f7d9fcc1e4f86862529454ec48bf7591d41a55 Mon Sep 17 00:00:00 2001 From: shilei Date: Sat, 3 Dec 2022 17:25:08 +0800 Subject: [PATCH] fix problem Signed-off-by: shilei Change-Id: I1293986d7f74409b38a33825c08c501167f42ea6 --- frameworks/resmgr_lite/src/global_utils.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/frameworks/resmgr_lite/src/global_utils.c b/frameworks/resmgr_lite/src/global_utils.c index ecd778d..8dd6b6b 100644 --- a/frameworks/resmgr_lite/src/global_utils.c +++ b/frameworks/resmgr_lite/src/global_utils.c @@ -56,7 +56,7 @@ static uint32_t GetIdHeaderOffsetByLocale(const char *locale, const Key *keys, u static int32_t GetIdHeaderByOffset(int32_t file, uint32_t offset, IdHeader *idHeader); static int32_t CheckFilePath(const char *path, char *realResourcePath, int32_t length); -static GlobalUtilsImpl g_globalUtilsImpl = { +const static GlobalUtilsImpl g_globalUtilsImpl = { .GetOffsetByLocale = GetOffsetByLocale, .GetDefaultOffsetValue = GetDefaultOffsetValue, .GetKeyValue = GetKeyValue, @@ -517,5 +517,5 @@ static int32_t GetIdHeaderByOffset(int32_t file, uint32_t offset, IdHeader *idHe GlobalUtilsImpl *GetGlobalUtilsImpl(void) { - return &g_globalUtilsImpl; + return (GlobalUtilsImpl *)(&g_globalUtilsImpl); } -- Gitee