fuzzer: No alloc in redisFormatCommand() when fail
This commit is contained in:
parent
329eaf9bae
commit
1abe0c8285
@ -48,10 +48,9 @@ int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) {
|
||||
memcpy(new_str, data, size);
|
||||
new_str[size] = '\0';
|
||||
|
||||
redisFormatCommand(&cmd, new_str);
|
||||
|
||||
if (cmd != NULL)
|
||||
if (redisFormatCommand(&cmd, new_str) != -1)
|
||||
hi_free(cmd);
|
||||
|
||||
free(new_str);
|
||||
return 0;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user