0
0
mirror of https://github.com/OpenVPN/openvpn3.git synced 2024-09-20 12:12:15 +02:00

ovpn3 client routing : add pushed routes even when

redirect-gateway is also pushed.
This commit is contained in:
James Yonan 2016-05-16 11:38:20 -06:00
parent 217734a398
commit ded4eb8667

View File

@ -381,8 +381,7 @@ namespace openvpn {
if (pair.version() != IP::Addr::V4)
throw tun_prop_error("route is not IPv4");
const bool add = route_target(o, 3);
if (!ipv.rgv4() || !add)
add_exclude_route(tb, add, pair.addr, pair.netmask.prefix_len(), metric, false, eer);
add_exclude_route(tb, add, pair.addr, pair.netmask.prefix_len(), metric, false, eer);
}
catch (const std::exception& e)
{
@ -410,8 +409,7 @@ namespace openvpn {
if (pair.version() != IP::Addr::V6)
throw tun_prop_error("route is not IPv6");
const bool add = route_target(o, 2);
if (!ipv.rgv6() || !add)
add_exclude_route(tb, add, pair.addr, pair.netmask.prefix_len(), metric, true, eer);
add_exclude_route(tb, add, pair.addr, pair.netmask.prefix_len(), metric, true, eer);
}
catch (const std::exception& e)
{