Fixed nexthop lookup, used by source route installation
This commit is contained in:
@@ -851,13 +851,10 @@ static host_t *get_route(private_kernel_netlink_net_t *this, host_t *dest,
|
|||||||
|
|
||||||
if (nexthop)
|
if (nexthop)
|
||||||
{
|
{
|
||||||
/* nexthop lookup, return gateway */
|
/* nexthop lookup, return gateway if any */
|
||||||
if (rta_gtw.ptr)
|
DESTROY_IF(gtw);
|
||||||
{
|
gtw = host_create_from_chunk(msg->rtm_family, rta_gtw, 0);
|
||||||
DESTROY_IF(gtw);
|
best = msg->rtm_dst_len;
|
||||||
gtw = host_create_from_chunk(msg->rtm_family, rta_gtw, 0);
|
|
||||||
best = msg->rtm_dst_len;
|
|
||||||
}
|
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
if (rta_src.ptr)
|
if (rta_src.ptr)
|
||||||
|
|||||||
Reference in New Issue
Block a user