update test/fuzztest/fscryptutils_fuzzer/fscryptutils_fuzzer.cpp.

Signed-off-by: zhuhongtao666 <zhuhongtao12@huawei.com>
This commit is contained in:
zhuhongtao666 2022-11-17 10:48:23 +00:00 committed by Gitee
parent 05fb526068
commit f408fac9a4
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F

View File

@ -21,7 +21,7 @@
namespace OHOS {
bool FscryptUtilsFuzzTest(const uint8_t *data, size_t size)
{
if ((data == nullptr) || (size <= 0)) {
if ((data == nullptr) || (size <= sizeof(char))) {
return false;
}
char character = *(reinterpret_cast<const char *>(data));