Software /
code /
prosody
Comparison
core/s2smanager.lua @ 959:e3db909065f2
sessionmanager, s2smanager, mod_component: Send reply </stream:stream> when client closes stream
author | Matthew Wild <mwild1@gmail.com> |
---|---|
date | Sun, 05 Apr 2009 20:06:39 +0100 |
parent | 938:663f75dd7b42 |
child | 960:6bc16062da6c |
comparison
equal
deleted
inserted
replaced
958:172fb9a73017 | 959:e3db909065f2 |
---|---|
242 end | 242 end |
243 | 243 |
244 session.notopen = nil; | 244 session.notopen = nil; |
245 end | 245 end |
246 | 246 |
247 function streamclosed(session) | |
248 session.send("</stream:stream>"); | |
249 session.notopen = true; | |
250 end | |
251 | |
247 function initiate_dialback(session) | 252 function initiate_dialback(session) |
248 -- generate dialback key | 253 -- generate dialback key |
249 session.dialback_key = generate_dialback(session.streamid, session.to_host, session.from_host); | 254 session.dialback_key = generate_dialback(session.streamid, session.to_host, session.from_host); |
250 session.sends2s(format("<db:result from='%s' to='%s'>%s</db:result>", session.from_host, session.to_host, session.dialback_key)); | 255 session.sends2s(format("<db:result from='%s' to='%s'>%s</db:result>", session.from_host, session.to_host, session.dialback_key)); |
251 session.log("info", "sent dialback key on outgoing s2s stream"); | 256 session.log("info", "sent dialback key on outgoing s2s stream"); |