Software /
code /
prosody
Diff
net/server_epoll.lua @ 7599:afbda0bd9cfc
net.server_epoll: Add separate timout for initial connection
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Thu, 18 Aug 2016 17:13:22 +0200 |
parent | 7598:335b5ce06062 |
child | 7600:a18532076efe |
line wrap: on
line diff
--- a/net/server_epoll.lua Thu Aug 18 17:07:14 2016 +0200 +++ b/net/server_epoll.lua Thu Aug 18 17:13:22 2016 +0200 @@ -30,6 +30,7 @@ tcp_backlog = 128; accept_retry_interval = 10; read_retry_delay = 1e-06; + connect_timeout = 20; handshake_timeout = 60; }; @@ -464,8 +465,8 @@ return self:starttls(); else self:setflags(false, true); + self:setwritetimeout(cfg.connect_timeout); end - self:setreadtimeout(); end function interface:pause()