summaryrefslogtreecommitdiffstats
path: root/src/plugins/nat/nat44-ei/nat44_ei_cli.c
diff options
context:
space:
mode:
authorKlement Sekera <ksekera@cisco.com>2021-10-22 12:52:34 +0200
committerDamjan Marion <dmarion@me.com>2021-10-30 11:04:12 +0000
commit001eb927db9ffb364d08440ca49266f70d674e6f (patch)
tree8dd9d81c0b61ff151f78d5a1d798883df0818e31 /src/plugins/nat/nat44-ei/nat44_ei_cli.c
parentba87563bee400f8ce6d99842a6e455c898cf2c1d (diff)
nat: fix coverity warning
Fix coverity warning by initialising proto variable to a dummy value. This value is never used because consuming function uses this parameter value only if is_addr_only flag is not set and this flag is always set if proto value is not provided by user. Type: fix Signed-off-by: Klement Sekera <ksekera@cisco.com> Change-Id: I041bc821a392f0746ef9f07f9b259d62884305b7
Diffstat (limited to 'src/plugins/nat/nat44-ei/nat44_ei_cli.c')
-rw-r--r--src/plugins/nat/nat44-ei/nat44_ei_cli.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/plugins/nat/nat44-ei/nat44_ei_cli.c b/src/plugins/nat/nat44-ei/nat44_ei_cli.c
index f3e71982e5c..36d98a46cb0 100644
--- a/src/plugins/nat/nat44-ei/nat44_ei_cli.c
+++ b/src/plugins/nat/nat44-ei/nat44_ei_cli.c
@@ -1112,7 +1112,7 @@ add_identity_mapping_command_fn (vlib_main_t *vm, unformat_input_t *input,
int rv, is_add = 1, port_set = 0;
u32 sw_if_index = ~0, port, flags, vrf_id = ~0;
- nat_protocol_t proto;
+ nat_protocol_t proto = NAT_PROTOCOL_OTHER;
ip4_address_t addr;
flags = NAT44_EI_SM_FLAG_IDENTITY_NAT;