aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorBenoît Ganne <bganne@cisco.com>2019-12-16 15:51:38 +0100
committerDamjan Marion <dmarion@me.com>2019-12-17 17:51:52 +0000
commit70ef0faea9f706004c068fb843797a7cb08a9e68 (patch)
tree400fa3af099336f16a9a4b63426cf57d48c8176b /src
parentedf3b4b04cc02707cf8aafe8fafe1296904a8b66 (diff)
l2: fix l2input_feat_names overflow
Type: fix Change-Id: I59549b3aab5a0ccfe7db02757f78528e028121a5 Signed-off-by: Benoît Ganne <bganne@cisco.com>
Diffstat (limited to 'src')
-rw-r--r--src/vnet/l2/l2_input.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/vnet/l2/l2_input.c b/src/vnet/l2/l2_input.c
index 4efb5562806..7b93fba20b1 100644
--- a/src/vnet/l2/l2_input.c
+++ b/src/vnet/l2/l2_input.c
@@ -83,7 +83,7 @@ format_l2_input_features (u8 * s, va_list * args)
feature_bitmap &= ~L2INPUT_FEAT_DROP; /* Not a feature */
int i;
- for (i = L2INPUT_N_FEAT; i >= 0; i--)
+ for (i = L2INPUT_N_FEAT - 1; i >= 0; i--)
{
if (feature_bitmap & (1 << i))
{