aboutsummaryrefslogtreecommitdiff
path: root/src/lib/ndpi_domains.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/ndpi_domains.c')
-rw-r--r--src/lib/ndpi_domains.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lib/ndpi_domains.c b/src/lib/ndpi_domains.c
index 05153d577..f4398b1c8 100644
--- a/src/lib/ndpi_domains.c
+++ b/src/lib/ndpi_domains.c
@@ -148,7 +148,7 @@ const char* ndpi_get_host_domain(struct ndpi_detection_module_struct *ndpi_str,
dot = strstr(hostname, ret);
- if(dot == NULL)
+ if(dot == NULL || dot == hostname)
return(hostname);
dot--;