Skip to content

Commit

Permalink
Debug 2
Browse files Browse the repository at this point in the history
Signed-off-by: Maxence Younsi <[email protected]>
  • Loading branch information
mxyns committed Nov 30, 2023
1 parent bbbbabd commit 72ca5f7
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion bgpd/bgp_route.c
Original file line number Diff line number Diff line change
Expand Up @@ -3408,6 +3408,9 @@ static void bgp_process_main_one(struct bgp *bgp, struct bgp_dest *dest,
* set
*/
if (old_select || new_select) {
if (old_select)
bgp_path_info_lock(old_select, __func__);

hook_call(bgp_route_update, bgp, afi, safi, dest, old_select,
new_select);
}
Expand Down Expand Up @@ -3589,6 +3592,7 @@ static void bgp_process_main_one(struct bgp *bgp, struct bgp_dest *dest,

/* Reap old select bgp_path_info, if it has been removed */
if (old_select && CHECK_FLAG(old_select->flags, BGP_PATH_REMOVED)) {
zlog_info("bgp reap old path %p", old_select);
bgp_path_info_reap(dest, old_select);
}

Expand All @@ -3599,6 +3603,7 @@ static void bgp_process_main_one(struct bgp *bgp, struct bgp_dest *dest,
old_select->peer->stat_loc_rib_count[afi][safi]--;

hook_call(bgp_process_main_one_end, bgp, old_select);
bgp_path_info_unlock(old_select, __func__);
}

if (new_select && new_select->peer)
Expand All @@ -3619,7 +3624,6 @@ static void bgp_process_main_one(struct bgp *bgp, struct bgp_dest *dest,
}
bgp_mpath_diff_clear(&mpath_diff);
bgp_mpath_diff_fini(&mpath_diff);
return;
}

/* Process the routes with the flag BGP_NODE_SELECT_DEFER set */
Expand Down

0 comments on commit 72ca5f7

Please sign in to comment.