mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-11 20:48:27 +00:00
bgpd: simplify lookup list call with fs pbr entries
no test is done to check for validity of fs_pbr and fs_iprule pointer. Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
This commit is contained in:
parent
2fe55afeec
commit
e0c7edb0cb
@ -2067,9 +2067,9 @@ static void bgp_pbr_policyroute_add_to_zebra_unit(struct bgp *bgp,
|
||||
struct bgp_path_info_extra *extra =
|
||||
bgp_path_info_extra_get(path);
|
||||
|
||||
if (extra && extra->bgp_fs_iprule &&
|
||||
listnode_lookup(extra->bgp_fs_iprule,
|
||||
bpr)) {
|
||||
if (extra &&
|
||||
listnode_lookup_nocheck(extra->bgp_fs_iprule,
|
||||
bpr)) {
|
||||
if (BGP_DEBUG(pbr, PBR_ERROR))
|
||||
zlog_err("%s: entry %p/%p already "
|
||||
"installed in bgp pbr iprule",
|
||||
@ -2216,8 +2216,8 @@ static void bgp_pbr_policyroute_add_to_zebra_unit(struct bgp *bgp,
|
||||
struct bgp_path_info_extra *extra =
|
||||
bgp_path_info_extra_get(path);
|
||||
|
||||
if (extra && extra->bgp_fs_pbr &&
|
||||
listnode_lookup(extra->bgp_fs_pbr, bpme)) {
|
||||
if (extra &&
|
||||
listnode_lookup_nocheck(extra->bgp_fs_pbr, bpme)) {
|
||||
if (BGP_DEBUG(pbr, PBR_ERROR))
|
||||
zlog_err(
|
||||
"%s: entry %p/%p already installed in bgp pbr",
|
||||
|
Loading…
Reference in New Issue
Block a user