Added check

This commit is contained in:
Luca Deri
2022-05-30 22:39:23 +02:00
parent 00ee364a7e
commit b3bf695723
+3 -1
View File
@@ -2528,7 +2528,9 @@ char* ndpi_get_flow_risk_info(struct ndpi_flow_struct *flow,
u_int8_t use_json) {
u_int i, offset = 0;
if((out == NULL) || (flow->num_risk_infos == 0))
if((out == NULL)
|| (flow == NULL)
|| (flow->num_risk_infos == 0))
return(NULL);
if(use_json) {