From d0b83a7196d3c81d3aded1d7b240c731a3f6f1f4 Mon Sep 17 00:00:00 2001 From: Luca Date: Thu, 21 Jan 2016 13:52:52 +0100 Subject: Minor change to ndpi_protocol2name() --- src/lib/ndpi_main.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/lib') diff --git a/src/lib/ndpi_main.c b/src/lib/ndpi_main.c index cffcbd78c..9d9c38edc 100644 --- a/src/lib/ndpi_main.c +++ b/src/lib/ndpi_main.c @@ -4195,7 +4195,8 @@ ndpi_protocol ndpi_guess_undetected_protocol(struct ndpi_detection_module_struct char* ndpi_protocol2name(struct ndpi_detection_module_struct *ndpi_mod, ndpi_protocol proto, char *buf, u_int buf_len) { - if(proto.master_protocol != NDPI_PROTOCOL_UNKNOWN) { + if((proto.master_protocol != NDPI_PROTOCOL_UNKNOWN) + && (proto.master_protocol != proto.protocol)) { snprintf(buf, buf_len, "%s.%s", ndpi_get_proto_name(ndpi_mod, proto.master_protocol), ndpi_get_proto_name(ndpi_mod, proto.protocol)); -- cgit v1.2.3