summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorOle Troan <ot@cisco.com>2019-06-18 13:56:05 +0200
committerNeale Ranns <nranns@cisco.com>2019-06-18 13:01:42 +0000
commit39baa32186fd3e4b20d9f58afbbfe7b8daebed62 (patch)
treecaae1d42d99ec9139b9020db2856e59c9b89d7eb /src
parent92e3082199d10add866894e86a9762d79a3536c4 (diff)
stats: off by one error in /sys/node/{calls,clocks,...}
Fixes: 58492a8372 Change-Id: Ia2eeebc2488b57e57f8d5e52f9948d1cced7b6fc Type: fix Ticket: VPP-1698 Signed-off-by: Ole Troan <ot@cisco.com>
Diffstat (limited to 'src')
-rw-r--r--src/vpp/stats/stat_segment.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/vpp/stats/stat_segment.c b/src/vpp/stats/stat_segment.c
index c3521cf3dcf..ec0bcf93690 100644
--- a/src/vpp/stats/stat_segment.c
+++ b/src/vpp/stats/stat_segment.c
@@ -449,13 +449,13 @@ update_node_counters (stat_segment_main_t * sm)
vlib_stat_segment_lock ();
stat_validate_counter_vector (&sm->directory_vector
- [STAT_COUNTER_NODE_CLOCKS], l);
+ [STAT_COUNTER_NODE_CLOCKS], l - 1);
stat_validate_counter_vector (&sm->directory_vector
- [STAT_COUNTER_NODE_VECTORS], l);
+ [STAT_COUNTER_NODE_VECTORS], l - 1);
stat_validate_counter_vector (&sm->directory_vector
- [STAT_COUNTER_NODE_CALLS], l);
+ [STAT_COUNTER_NODE_CALLS], l - 1);
stat_validate_counter_vector (&sm->directory_vector
- [STAT_COUNTER_NODE_SUSPENDS], l);
+ [STAT_COUNTER_NODE_SUSPENDS], l - 1);
vec_validate (sm->nodes, l - 1);
stat_segment_directory_entry_t *ep;