Diff

core/sessionmanager.lua @ 11518:3f1a865e9419

core.sessionmanager: Add a dummy rawsend() method to resting sessions Should fix a traceback on attempted use after destruction, in case where opportunistic_writes was in use. Thanks Ge0rG
author Kim Alvefur <zash@zash.se>
date Thu, 15 Apr 2021 15:12:35 +0200
parent 10642:de90b2f5da8c
child 12642:9061f9621330
child 12877:f6cca7cbf3b2
line wrap: on
line diff
--- a/core/sessionmanager.lua	Wed Apr 14 16:02:47 2021 +0200
+++ b/core/sessionmanager.lua	Thu Apr 15 15:12:35 2021 +0200
@@ -86,6 +86,7 @@
 	end
 
 	function session.send(data) log("debug", "Discarding data sent to resting session: %s", data); return false; end
+	function session.rawsend(data) log("debug", "Discarding data sent to resting session: %s", data); return false; end
 	function session.data(data) log("debug", "Discarding data received from resting session: %s", data); end
 	session.thread = { run = function (_, data) return session.data(data) end };
 	return setmetatable(session, resting_session);