bgpd: mplsvpn snmp: NULL check correct pointer

Check the dereferenced pointer to the bgp instance and not the
pointer to it.

Signed-off-by: Pat Ruddy <pat@voltanet.io>
This commit is contained in:
Pat Ruddy 2021-02-14 12:08:08 +00:00
parent f01828a1d7
commit 23b88a967d

View File

@ -1461,7 +1461,7 @@ static struct bgp_path_info *bgpL3vpnRte_lookup(struct variable *v, oid name[],
/* otherwise lookup the one we have */
*l3vpn_bgp = bgp_lookup_by_name(vrf_name);
if (l3vpn_bgp == NULL)
if (*l3vpn_bgp == NULL)
return NULL;
pi = bgp_lookup_route_next(l3vpn_bgp, dest, &prefix, policy,