From 56d5c1eedf22a1d384120466e6004faf9933d113 Mon Sep 17 00:00:00 2001 From: Ori Kam Date: Thu, 30 Jan 2020 16:59:35 +0000 Subject: [PATCH] app/testpmd: fix uninitialized members of MPLS Some of the members of the MPLS struct are not initialized. This commit init the uninitialized members. Coverity issue: 325735 Fixes: 3e77031be855 ("app/testpmd: add MPLSoGRE encapsulation") Cc: stable@dpdk.org Signed-off-by: Ori Kam Reviewed-by: Ferruh Yigit --- app/test-pmd/cmdline_flow.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/app/test-pmd/cmdline_flow.c b/app/test-pmd/cmdline_flow.c index e99e24c29f..c2cc4c57b8 100644 --- a/app/test-pmd/cmdline_flow.c +++ b/app/test-pmd/cmdline_flow.c @@ -4576,7 +4576,9 @@ parse_vc_action_mplsogre_encap(struct context *ctx, const struct token *token, struct rte_flow_item_gre gre = { .protocol = rte_cpu_to_be_16(ETHER_TYPE_MPLS_UNICAST), }; - struct rte_flow_item_mpls mpls; + struct rte_flow_item_mpls mpls = { + .ttl = 0, + }; uint8_t *header; int ret; -- 2.20.1