mirror of
https://github.com/OpenVPN/openvpn.git
synced 2026-05-28 04:03:29 -04:00
Error message if max-routes used incorrectly
the route/route-ipv6/redirect-gateway options allocate the route structe with max_routes number of routes. A max-routes after any of this commands has no effect. This can be problematic (http://code.google.com/p/ics-openvpn/issues/detail?id=101) Signed-off-by: Arne Schwabe <arne@rfc2549.org> Acked-by: Gert Doering <gert@greenie.muc.de> Message-Id: 1353348737-21920-1-git-send-email-arne@rfc2549.org URL: http://article.gmane.org/gmane.network.openvpn.devel/7131 Signed-off-by: David Sommerseth <davids@redhat.com>
This commit is contained in:
parent
5fd3e56430
commit
f83ccec652
1 changed files with 5 additions and 0 deletions
|
|
@ -5141,6 +5141,11 @@ add_option (struct options *options,
|
|||
msg (msglevel, "--max-routes parameter is out of range");
|
||||
goto err;
|
||||
}
|
||||
if (options->routes || options->routes_ipv6)
|
||||
{
|
||||
msg (msglevel, "--max-routes must to be specifed before any route/route-ipv6/redirect-gateway option");
|
||||
goto err;
|
||||
}
|
||||
options->max_routes = max_routes;
|
||||
}
|
||||
else if (streq (p[0], "route-gateway") && p[1])
|
||||
|
|
|
|||
Loading…
Reference in a new issue