summaryrefslogtreecommitdiff
path: root/zebra/zebra_rib.c
diff options
context:
space:
mode:
authorEmanuele Di Pascale <emanuele@voltanet.io>2020-12-21 13:17:09 +0100
committerEmanuele Di Pascale <emanuele@voltanet.io>2020-12-21 14:34:55 +0100
commit2e8db20d7eefbbc45aa64c8f5d61be276184a69c (patch)
treeffeee52ad1925bea404f39787758c041f86fb3d6 /zebra/zebra_rib.c
parent6c5f54180aef4635218686b1ccc4fc90fde187d2 (diff)
zebra: avoid c++ reserved keyword
in rib_handle_nhg_replace, do not use new as a parameter name to allow compilation of c++ code including zebra headers. Signed-off-by: Emanuele Di Pascale <emanuele@voltanet.io>
Diffstat (limited to 'zebra/zebra_rib.c')
-rw-r--r--zebra/zebra_rib.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/zebra/zebra_rib.c b/zebra/zebra_rib.c
index 0aea0b6cfa..dc295f8926 100644
--- a/zebra/zebra_rib.c
+++ b/zebra/zebra_rib.c
@@ -250,8 +250,8 @@ done:
return ret;
}
-void rib_handle_nhg_replace(struct nhg_hash_entry *old,
- struct nhg_hash_entry *new)
+void rib_handle_nhg_replace(struct nhg_hash_entry *old_entry,
+ struct nhg_hash_entry *new_entry)
{
struct zebra_router_table *zrt;
struct route_node *rn;
@@ -259,15 +259,15 @@ void rib_handle_nhg_replace(struct nhg_hash_entry *old,
if (IS_ZEBRA_DEBUG_RIB_DETAILED || IS_ZEBRA_DEBUG_NHG_DETAIL)
zlog_debug("%s: replacing routes nhe (%u) OLD %p NEW %p",
- __func__, new->id, new, old);
+ __func__, new_entry->id, new_entry, old_entry);
/* We have to do them ALL */
RB_FOREACH (zrt, zebra_router_table_head, &zrouter.tables) {
for (rn = route_top(zrt->table); rn;
rn = srcdest_route_next(rn)) {
RNODE_FOREACH_RE_SAFE (rn, re, next) {
- if (re->nhe && re->nhe == old)
- route_entry_update_nhe(re, new);
+ if (re->nhe && re->nhe == old_entry)
+ route_entry_update_nhe(re, new_entry);
}
}
}