summaryrefslogtreecommitdiffstats
path: root/forward.c
diff options
context:
space:
mode:
authorjames <james@e7ae566f-a301-0410-adde-c780ea21d3b5>2009-11-19 16:42:51 +0000
committerjames <james@e7ae566f-a301-0410-adde-c780ea21d3b5>2009-11-19 16:42:51 +0000
commit5c30df12ae98c0289cdfb2a24aefba2a9d2cc52e (patch)
treeb900adb66ca9a3c7d57fb89fe647f6772df027f9 /forward.c
parentb9437c64ddd36c7c13508977e1a348d0e45d3187 (diff)
downloadopenvpn-5c30df12ae98c0289cdfb2a24aefba2a9d2cc52e.tar.gz
openvpn-5c30df12ae98c0289cdfb2a24aefba2a9d2cc52e.tar.xz
openvpn-5c30df12ae98c0289cdfb2a24aefba2a9d2cc52e.zip
Fixed a client-side bug that occurred when the "dhcp-pre-release"
or "dhcp-renew" options were combined with "route-gateway dhcp". The problem is that the IP Helper functions for DHCP release and renew are blocking, and so calling them from a single-threaded client stops tunnel traffic forwarding, and hence breaks "route-gateway dhcp" which requires an active tunnel. The fix is to call the IP Helper functions for DHCP release and renew from another process. Version 2.1_rc21b. git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@5164 e7ae566f-a301-0410-adde-c780ea21d3b5
Diffstat (limited to 'forward.c')
-rw-r--r--forward.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/forward.c b/forward.c
index 661ac5c..207b876 100644
--- a/forward.c
+++ b/forward.c
@@ -1040,7 +1040,8 @@ process_ipv4_header (struct context *c, unsigned int flags, struct buffer *buf)
if (flags & PIPV4_EXTRACT_DHCP_ROUTER)
{
const in_addr_t dhcp_router = dhcp_extract_router_msg (&ipbuf);
- route_list_add_default_gateway (c->c1.route_list, c->c2.es, dhcp_router);
+ if (dhcp_router)
+ route_list_add_default_gateway (c->c1.route_list, c->c2.es, dhcp_router);
}
}
}