fuzz: some enhancements (#1827)
Load some custom configuration (like in the unit tests) and factorize some (fuzzing) common code. There is no way to pass file paths to the fuzzers as parameters. The safe solution seems to be to load them from the process working dir. Anyway, missing file is not a blocking error. Remove some dead code (found looking at the coverage report)
This commit is contained in:
@@ -106,7 +106,7 @@ void ndpi_search_memcached(
|
||||
struct ndpi_packet_struct *packet = &ndpi_struct->packet;
|
||||
const u_int8_t *offset = packet->payload;
|
||||
u_int16_t length = packet->payload_packet_len;
|
||||
u_int8_t *matches;
|
||||
u_int8_t *matches = NULL;
|
||||
|
||||
NDPI_LOG_DBG(ndpi_struct, "search memcached\n");
|
||||
|
||||
@@ -134,10 +134,6 @@ void ndpi_search_memcached(
|
||||
length -= MEMCACHED_UDP_HDR_LEN;
|
||||
matches = &flow->l4.udp.memcached_matches;
|
||||
}
|
||||
else {
|
||||
NDPI_EXCLUDE_PROTO(ndpi_struct, flow);
|
||||
return;
|
||||
}
|
||||
|
||||
/* grep MCD memcached.c |\
|
||||
* egrep -v '(LEN|MATCH)' |\
|
||||
|
||||
Reference in New Issue
Block a user