diff options
author | Kim Alvefur <zash@zash.se> | 2016-08-18 17:13:22 +0200 |
---|---|---|
committer | Kim Alvefur <zash@zash.se> | 2016-08-18 17:13:22 +0200 |
commit | 1a8fd7920f15c0783c5957ec217723e92fa44b10 (patch) | |
tree | 76983e2bfab8bdeedccb0e7951ee7a0c51ab67ea /net | |
parent | e72b357bd7d697cfafa923b53daa226fdca91ae0 (diff) | |
download | prosody-1a8fd7920f15c0783c5957ec217723e92fa44b10.tar.gz prosody-1a8fd7920f15c0783c5957ec217723e92fa44b10.zip |
net.server_epoll: Add separate timout for initial connection
Diffstat (limited to 'net')
-rw-r--r-- | net/server_epoll.lua | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/net/server_epoll.lua b/net/server_epoll.lua index 2374ab57..c4ae7133 100644 --- a/net/server_epoll.lua +++ b/net/server_epoll.lua @@ -30,6 +30,7 @@ local cfg = { tcp_backlog = 128; accept_retry_interval = 10; read_retry_delay = 1e-06; + connect_timeout = 20; handshake_timeout = 60; }; @@ -464,8 +465,8 @@ function interface:init() return self:starttls(); else self:setflags(false, true); + self:setwritetimeout(cfg.connect_timeout); end - self:setreadtimeout(); end function interface:pause() |