Changeset

9579:185eed6cbab0

net.server_select: Replace use of deprecated :lock_read in server.link
author Kim Alvefur <zash@zash.se>
date Sun, 28 Oct 2018 17:08:50 +0100
parents 9578:1ef33635f3f0
children 9580:5fe91bfb734c
files net/server_select.lua
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/net/server_select.lua	Sun Oct 28 16:55:21 2018 +0100
+++ b/net/server_select.lua	Sun Oct 28 17:08:50 2018 +0100
@@ -719,7 +719,7 @@
 	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 @@
 		_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");