From 6c5ecae607e98e0bdd0ca8500d2003db3a5f9688 Mon Sep 17 00:00:00 2001 From: Ivan Nardi <12729895+IvanNardi@users.noreply.github.com> Date: Thu, 1 Feb 2024 17:06:16 +0100 Subject: Fix function parameters check on domain code (#2296) Found while fuzzing fuzz_config --- src/lib/ndpi_domains.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/lib/ndpi_domains.c b/src/lib/ndpi_domains.c index e679c3fc0..7970f3a36 100644 --- a/src/lib/ndpi_domains.c +++ b/src/lib/ndpi_domains.c @@ -31,7 +31,7 @@ int ndpi_load_domain_suffixes(struct ndpi_detection_module_struct *ndpi_str, FILE *fd; u_int num_domains = 0; - if(public_suffix_list_path == NULL) + if(ndpi_str == NULL || public_suffix_list_path == NULL) return(-1); if((fd = fopen(public_suffix_list_path, "r")) == NULL) -- cgit v1.2.3