aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKim Alvefur <zash@zash.se>2018-10-29 02:13:09 +0100
committerKim Alvefur <zash@zash.se>2018-10-29 02:13:09 +0100
commit9270a17d2089c16c1cb37040f55638867b5adfbe (patch)
tree4f7f80c60a404082d62a40817d69ab3232c4cfe5
parent81a8dca01e7df9f7dbf7478ccac4ada001a88b6d (diff)
downloadprosody-9270a17d2089c16c1cb37040f55638867b5adfbe.tar.gz
prosody-9270a17d2089c16c1cb37040f55638867b5adfbe.zip
net.server_epoll: Use method to update peername on connect
-rw-r--r--net/server_epoll.lua4
1 files changed, 1 insertions, 3 deletions
diff --git a/net/server_epoll.lua b/net/server_epoll.lua
index ce8996a8..f7e5ae49 100644
--- a/net/server_epoll.lua
+++ b/net/server_epoll.lua
@@ -612,9 +612,7 @@ end
-- Connected!
function interface:onconnect()
- if self.conn and not self.peername and self.conn.getpeername then
- self.peername, self.peerport = self.conn:getpeername();
- end
+ self:updatenames();
self.onconnect = noop;
self:on("connect");
end