Comparison

core/s2smanager.lua @ 11418:f4b76e500768

core.s2smanager: Set "direction" on destroyed sessions (fixes #1641) Should prevent errors in certain places where it logs session.direction captialized using gsub. Might cause bugs tho, but then the session is destroyed so maybe it doesn't matter?
author Kim Alvefur <zash@zash.se>
date Wed, 03 Mar 2021 13:30:19 +0100
parent 10425:42cf93ff4618
child 11900:60676b607b6d
comparison
equal deleted inserted replaced
11417:f84005d06663 11418:f4b76e500768
53 end 53 end
54 54
55 local resting_session = { -- Resting, not dead 55 local resting_session = { -- Resting, not dead
56 destroyed = true; 56 destroyed = true;
57 type = "s2s_destroyed"; 57 type = "s2s_destroyed";
58 direction = "destroyed";
58 open_stream = function (session) 59 open_stream = function (session)
59 session.log("debug", "Attempt to open stream on resting session"); 60 session.log("debug", "Attempt to open stream on resting session");
60 end; 61 end;
61 close = function (session) 62 close = function (session)
62 session.log("debug", "Attempt to close already-closed session"); 63 session.log("debug", "Attempt to close already-closed session");