mirror of
https://gitee.com/openharmony/communication_wifi.git
synced 2024-12-26 08:56:37 +00:00
新增Fuzz接口
Signed-off-by: sunjingqiang <17319862417@163.com>
This commit is contained in:
parent
35534a7d9e
commit
ccf2e4b605
@ -257,7 +257,7 @@ public:
|
||||
}
|
||||
};
|
||||
|
||||
bool DoSomethingInterestingWithMyAPI(const uint8_t* data, size_t size)
|
||||
bool DoSomethingInterestingWithMyAPI(const char* data, size_t size)
|
||||
{
|
||||
MessageParcel datas;
|
||||
datas.WriteInterfaceToken(FORMMGR_INTERFACE_TOKEN);
|
||||
@ -287,7 +287,7 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size)
|
||||
if (size == 0 || size > OHOS::Wifi::FOO_MAX_LEN) {
|
||||
return 0;
|
||||
}
|
||||
uint8_t* ch = (uint8_t *)malloc(size + 1);
|
||||
char* ch = (char *)malloc(size + 1);
|
||||
if (ch == nullptr) {
|
||||
return 0;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user