aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMichele Campus <fci1908@gmail.com>2016-09-15 09:50:38 +0200
committerGitHub <noreply@github.com>2016-09-15 09:50:38 +0200
commit36956ebf683580ca9612975524f15024ff9a3acd (patch)
treebc1b18f4b08b7fa9791118fcbb108749a8f66ad5 /src
parent9e9b64a7e73009ca31e630a4878ceb216a8dd663 (diff)
parent3c8d5bb788d18bc13cf84174eef752b872929788 (diff)
Merge pull request #267 from tianzhishuizhu/dev
check udp
Diffstat (limited to 'src')
-rw-r--r--src/lib/protocols/vmware.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lib/protocols/vmware.c b/src/lib/protocols/vmware.c
index 0c2ffaa69..a6cbe5dc9 100644
--- a/src/lib/protocols/vmware.c
+++ b/src/lib/protocols/vmware.c
@@ -29,7 +29,7 @@ void ndpi_search_vmware(struct ndpi_detection_module_struct *ndpi_struct, struct
struct ndpi_packet_struct *packet = &flow->packet;
/* Check whether this is an VMWARE flow */
- if((packet->payload_packet_len == 66)
+ if(packet->udp != NULL && (packet->payload_packet_len == 66)
&& (ntohs(packet->udp->dest) == 902)
&& ((packet->payload[0] & 0xFF) == 0xA4)) {
NDPI_LOG(NDPI_PROTOCOL_VMWARE, ndpi_struct, NDPI_LOG_DEBUG, "Found vmware.\n");