summaryrefslogtreecommitdiffstats
path: root/init.c
diff options
context:
space:
mode:
authorjames <james@e7ae566f-a301-0410-adde-c780ea21d3b5>2005-11-25 00:05:56 +0000
committerjames <james@e7ae566f-a301-0410-adde-c780ea21d3b5>2005-11-25 00:05:56 +0000
commit1ae9d05173a5960eaf84dcb55b91374fa2bb6639 (patch)
tree0b82d974ee07015fe307ca213c88253252a57d51 /init.c
parentd5badcf116fcf744a8c99ffcdade6ebb48f56872 (diff)
downloadopenvpn-1ae9d05173a5960eaf84dcb55b91374fa2bb6639.tar.gz
openvpn-1ae9d05173a5960eaf84dcb55b91374fa2bb6639.tar.xz
openvpn-1ae9d05173a5960eaf84dcb55b91374fa2bb6639.zip
Added --connect-timeout option to control the timeout
on TCP client connection attempts (doesn't work on all OSes). This patch also makes OpenVPN signalable during TCP connection attempts. git-svn-id: http://svn.openvpn.net/projects/openvpn/branches/BETA21/openvpn@823 e7ae566f-a301-0410-adde-c780ea21d3b5
Diffstat (limited to 'init.c')
-rw-r--r--init.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/init.c b/init.c
index b3a999e..d6699e2 100644
--- a/init.c
+++ b/init.c
@@ -1673,7 +1673,11 @@ do_option_warnings (struct context *c)
&& !(o->ns_cert_type & NS_SSL_SERVER))
msg (M_WARN, "WARNING: No server certificate verification method has been enabled. See http://openvpn.net/howto.html#mitm for more info.");
#endif
+#endif
+#ifndef CONNECT_NONBLOCK
+ if (o->connect_timeout_defined)
+ msg (M_WARN, "NOTE: --connect-timeout option is not supported on this OS");
#endif
}
@@ -1813,6 +1817,7 @@ do_init_socket_1 (struct context *c, int mode)
c->plugins,
c->options.resolve_retry_seconds,
c->options.connect_retry_seconds,
+ c->options.connect_timeout,
c->options.connect_retry_max,
c->options.mtu_discover_type,
c->options.rcvbuf,