aboutsummaryrefslogtreecommitdiff
path: root/example/ndpi_util.c
diff options
context:
space:
mode:
authorLuca <deri@ntop.org>2017-05-08 08:29:18 +0200
committerLuca <deri@ntop.org>2017-05-08 08:29:18 +0200
commit21567e868642a3835491e8a5cf3650eee33b4d3c (patch)
treec27b1f90211817c00591c6b7d631d4c0b1a2e84f /example/ndpi_util.c
parent1af3d571d93c7baa8fd40322df775e98df01b402 (diff)
Added missing direction update with non TCP-UDP protocols
Diffstat (limited to 'example/ndpi_util.c')
-rw-r--r--example/ndpi_util.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/example/ndpi_util.c b/example/ndpi_util.c
index 1ba77eb80..f756fbaf5 100644
--- a/example/ndpi_util.c
+++ b/example/ndpi_util.c
@@ -318,6 +318,8 @@ static struct ndpi_flow_info *get_ndpi_flow_info(struct ndpi_workflow * workflow
// non tcp/udp protocols
lower_port = 0;
upper_port = 0;
+
+ *src_to_dst_direction = (iph->saddr < iph->daddr) ? 1 : 0;
}
flow.protocol = iph->protocol, flow.vlan_id = vlan_id;