dhcp: Fix classless static routes

Assign the netwask correctly from the message.

Cherry-picked from upstream in
https://dev.marples.name/rDHC510c760cb24ef4b1b16cc14732c5ffe0fbb0d96d.

This fixes route assignments when running on Google Compute Engine,
which uses classless static routes.
This commit is contained in:
bsiegert 2017-09-05 11:58:55 +00:00
parent 6a87a80ea4
commit 1eb43387d0
1 changed files with 1 additions and 1 deletions

View File

@ -452,7 +452,7 @@ decode_rfc3442_rt(struct rt_head *routes, struct interface *ifp,
}
sa_in_init(&rt->rt_dest, &dest);
sa_in_init(&rt->rt_dest, &netmask);
sa_in_init(&rt->rt_netmask, &netmask);
sa_in_init(&rt->rt_gateway, &gateway);
/* If CIDR is 32 then it's a host route. */