reader_util: stop processing a flow (#1666)
We should stop processing a flow if all protocols have been excluded or if we have already processed too many packets.
This commit is contained in:
@@ -6086,6 +6086,7 @@ ndpi_protocol ndpi_detection_process_packet(struct ndpi_detection_module_struct
|
||||
|
||||
if(ndpi_str->max_packets_to_process > 0 && flow->num_processed_pkts >= ndpi_str->max_packets_to_process) {
|
||||
flow->extra_packets_func = NULL; /* To allow ndpi_extra_dissection_possible() to fail */
|
||||
flow->fail_with_unknown = 1;
|
||||
return(ret); /* Avoid spending too much time with this flow */
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user