diff options
author | Campus <campus@ntop.org> | 2016-11-12 16:35:25 +0100 |
---|---|---|
committer | Campus <campus@ntop.org> | 2016-11-12 16:35:25 +0100 |
commit | 48a206a4347d38f0bed322d194ce40076417ac59 (patch) | |
tree | 0c3349a86f167b984e27f54416e6a5d5e2a69c95 /src/lib/protocols/coap.c | |
parent | 4564b973df4fd6bbc90782ee98f80e459416b244 (diff) | |
parent | 3a6d2c7c5f28dacca0a99f0e122e10807cce22fb (diff) |
Merge branch 'alagoutte-scan-build' into dev
Diffstat (limited to 'src/lib/protocols/coap.c')
-rw-r--r-- | src/lib/protocols/coap.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lib/protocols/coap.c b/src/lib/protocols/coap.c index 5f8e97863..252ffc9c4 100644 --- a/src/lib/protocols/coap.c +++ b/src/lib/protocols/coap.c @@ -115,7 +115,7 @@ void ndpi_search_coap (struct ndpi_detection_module_struct *ndpi_struct, u_int16_t s_port = ntohs(flow->packet.udp->source); u_int16_t d_port = ntohs(flow->packet.udp->dest); - if((!isCoAPport(s_port) && !isCoAPport(s_port)) + if((!isCoAPport(s_port) && !isCoAPport(d_port)) || (packet->payload_packet_len < 4) // header too short ) { NDPI_LOG(NDPI_PROTOCOL_COAP, ndpi_struct, NDPI_LOG_DEBUG, "excluding Coap\n"); |