Software /
code /
prosody
Changeset
10283:dff360d00dfa
net.server_epoll: Handle read size argument to link
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Sun, 29 Sep 2019 15:36:23 +0200 |
parents | 10282:05ba04725a15 |
children | 10284:cd669975031b |
files | net/server_epoll.lua |
diffstat | 1 files changed, 2 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/net/server_epoll.lua Sun Sep 29 15:18:40 2019 +0200 +++ b/net/server_epoll.lua Sun Sep 29 15:36:23 2019 +0200 @@ -791,7 +791,7 @@ end; -- Dump all data from one connection into another -local function link(from, to) +local function link(from, to, read_size) from:debug("Linking to %s", to.id); from.listeners = setmetatable({ onincoming = function (_, data) @@ -804,6 +804,7 @@ from:resume(); end, }, {__index=to.listeners}); + from:set_mode(read_size); from:set(true, nil); to:set(nil, true); end