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:
Ivan Nardi
2022-07-20 14:48:09 +02:00
committed by GitHub
parent b472a49271
commit c72660d7d3
14 changed files with 15 additions and 13 deletions
+1
View File
@@ -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 */
}