aboutsummaryrefslogtreecommitdiffstats
path: root/net/server_select.lua
diff options
context:
space:
mode:
authorKim Alvefur <zash@zash.se>2018-10-28 17:08:50 +0100
committerKim Alvefur <zash@zash.se>2018-10-28 17:08:50 +0100
commite21ccabfac08dfb94fda4236a3b7bc842dd54b80 (patch)
treeab5e176bb477c4fda4683bf3f47988c36fc09c0f /net/server_select.lua
parent193eebddaf36f0df296b70d858c97d66d5ad20bb (diff)
downloadprosody-e21ccabfac08dfb94fda4236a3b7bc842dd54b80.tar.gz
prosody-e21ccabfac08dfb94fda4236a3b7bc842dd54b80.zip
net.server_select: Replace use of deprecated :lock_read in server.link
Diffstat (limited to 'net/server_select.lua')
-rw-r--r--net/server_select.lua4
1 files changed, 2 insertions, 2 deletions
diff --git a/net/server_select.lua b/net/server_select.lua
index e30ac8fe..475f05b8 100644
--- a/net/server_select.lua
+++ b/net/server_select.lua
@@ -719,7 +719,7 @@ local function link(sender, receiver, buffersize)
function receiver.sendbuffer()
_sendbuffer();
if sender_locked and receiver.bufferlen() < buffersize then
- sender:lock_read(false); -- Unlock now
+ sender:resume(); -- Unlock now
sender_locked = nil;
end
end
@@ -729,7 +729,7 @@ local function link(sender, receiver, buffersize)
_readbuffer();
if not sender_locked and receiver.bufferlen() >= buffersize then
sender_locked = true;
- sender:lock_read(true);
+ sender:pause();
end
end
sender:set_mode("*a");