mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-09 03:47:47 +00:00
zebra: Fix broken rib_match
rib_match is broken because the prefix is being treated as a char * pointer instead of the correct data type. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com> (cherry picked from commit 8b5d6c95781b7c55faa957a2d3edf00c1ecb5c5a)
This commit is contained in:
parent
10fbd59a57
commit
d71f1c4e6f
@ -764,12 +764,16 @@ rib_match (afi_t afi, safi_t safi, vrf_id_t vrf_id,
|
|||||||
|
|
||||||
memset (&p, 0, sizeof (struct prefix));
|
memset (&p, 0, sizeof (struct prefix));
|
||||||
p.family = afi;
|
p.family = afi;
|
||||||
p.u.prefix = *(u_char *)addr;
|
|
||||||
p.prefixlen = IPV4_MAX_PREFIXLEN;
|
|
||||||
if (afi == AFI_IP)
|
if (afi == AFI_IP)
|
||||||
|
{
|
||||||
|
p.u.prefix4 = addr->ipv4;
|
||||||
p.prefixlen = IPV4_MAX_PREFIXLEN;
|
p.prefixlen = IPV4_MAX_PREFIXLEN;
|
||||||
|
}
|
||||||
else
|
else
|
||||||
|
{
|
||||||
|
p.u.prefix6 = addr->ipv6;
|
||||||
p.prefixlen = IPV6_MAX_PREFIXLEN;
|
p.prefixlen = IPV6_MAX_PREFIXLEN;
|
||||||
|
}
|
||||||
|
|
||||||
rn = route_node_match (table, (struct prefix *) &p);
|
rn = route_node_match (table, (struct prefix *) &p);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user