diff options
author | Donald Sharp <sharpd@nvidia.com> | 2020-10-02 13:18:58 +0200 |
---|---|---|
committer | Donald Sharp <sharpd@nvidia.com> | 2021-01-16 01:34:33 +0100 |
commit | 284a6f5ff1312265b48699310b5a5bc6ecb10e1a (patch) | |
tree | 0b90b06611aa647f6a2f86d62382edbf50dee95e /lib/routemap.c | |
parent | doc: Document the "zebra route-map delay-timer" functionality (diff) | |
download | frr-284a6f5ff1312265b48699310b5a5bc6ecb10e1a.tar.xz frr-284a6f5ff1312265b48699310b5a5bc6ecb10e1a.zip |
lib: Keep track of route-map applications per section
When the routemap code was rewritten for performance the
code to track the number of times a particular section of
a route-map was applied was not correctly updated. In
this case I found another sequence of events where the
number of times a section was invoked was not being correctly
kept.
Effectively in this case when route_map_get_index is called
and returns an index the route map has been applied( see that
skip_match_clause is set to true and then in the for loop
below the skip_match_clause is tested and index->applied is
incremented.
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
Diffstat (limited to 'lib/routemap.c')
-rw-r--r-- | lib/routemap.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/routemap.c b/lib/routemap.c index 1c2f43d96..360fd25cc 100644 --- a/lib/routemap.c +++ b/lib/routemap.c @@ -2399,6 +2399,7 @@ route_map_result_t route_map_apply(struct route_map *map, index = route_map_get_index(map, prefix, object, (uint8_t *)&match_ret); if (index) { + index->applied++; if (rmap_debug) zlog_debug( "Best match route-map: %s, sequence: %d for pfx: %pFX, result: %s", |