修改AclGetSerial 获取serial失败返回默认值问题

Signed-off-by: zhongning5 <zhongning5@huawei.com>
This commit is contained in:
zhongning5 2023-12-19 18:38:25 +08:00
parent 996a1c3cb2
commit 3c12c8816c

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 */