mirror of
https://github.com/openharmony/js_api_module.git
synced 2026-07-25 14:35:24 -04:00
Solve that Textdecode class cannot decode GBK, GB8030 and GB2312
Call the SetHwIcuDirectory() function to initialize the ICU data issue:https://gitee.com/openharmony/js_util_module/issues/I5BC1R Signed-off-by: xdmal <maxiaodong16@huawei.com>
This commit is contained in:
@@ -22,6 +22,7 @@
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
#include "ohos/init_data.h"
|
||||
#include "securec.h"
|
||||
#include "unicode/unistr.h"
|
||||
#include "utils/log.h"
|
||||
@@ -41,6 +42,7 @@ namespace OHOS::Util {
|
||||
}
|
||||
}
|
||||
label_ = i32Flag;
|
||||
SetHwIcuDirectory();
|
||||
bool fatal =
|
||||
(i32Flag & static_cast<uint32_t>(ConverterFlags::FATAL_FLG)) ==
|
||||
static_cast<uint32_t>(ConverterFlags::FATAL_FLG);
|
||||
|
||||
Reference in New Issue
Block a user