aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/snat/snat_ipfix_logging.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/plugins/snat/snat_ipfix_logging.c')
-rw-r--r--src/plugins/snat/snat_ipfix_logging.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/plugins/snat/snat_ipfix_logging.c b/src/plugins/snat/snat_ipfix_logging.c
index d72eb226675..9f1abb7d9f4 100644
--- a/src/plugins/snat/snat_ipfix_logging.c
+++ b/src/plugins/snat/snat_ipfix_logging.c
@@ -295,9 +295,7 @@ snat_ipfix_logging_nat44_ses (u8 nat_event, u32 src_ip, u32 nat_src_ip,
if (!silm->enabled)
return;
- proto = (snat_proto == SNAT_PROTOCOL_UDP) ? IP_PROTOCOL_UDP : proto;
- proto = (snat_proto == SNAT_PROTOCOL_TCP) ? IP_PROTOCOL_TCP : proto;
- proto = (snat_proto == SNAT_PROTOCOL_ICMP) ? IP_PROTOCOL_ICMP : proto;
+ proto = snat_proto_to_ip_proto (snat_proto);
now = (u64) ((vlib_time_now (vm) - silm->vlib_time_0) * 1e3);
now += silm->milisecond_time_0;