!2427 FIX:修改AclGetSerial 获取serial失败返回默认值问题

Merge pull request !2427 from 钟柠/1219_sn
This commit is contained in:
openharmony_ci 2023-12-20 02:54:07 +00:00 committed by Gitee
commit 1f4b33ae42
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F

View File

@ -47,7 +47,7 @@ int AclGetDevUdid(char *udid, int size)
const char *AclGetSerial(void)
{
static char serialNumber[MAX_SERIAL_LEN] = {"1234567890"};
static char serialNumber[MAX_SERIAL_LEN] = {0};
#ifdef PARAM_FEATURE_DEVICEINFO
std::string result = {};
OHOS::device_info::DeviceInfoKits &instance = OHOS::device_info::DeviceInfoKits::GetInstance();
@ -70,4 +70,4 @@ const char *AclGetSerial(void)
#if __cplusplus
}
#endif
#endif /* __cplusplus */
#endif /* __cplusplus */