aboutsummaryrefslogtreecommitdiffstats
path: root/plugins/mod_bosh.lua
diff options
context:
space:
mode:
authorKim Alvefur <zash@zash.se>2017-04-20 00:41:49 +0200
committerKim Alvefur <zash@zash.se>2017-04-20 00:41:49 +0200
commita7b9c6de423f4f4572aaf81674903a27fbcd7c67 (patch)
tree6807f13197827f810a9a2cd3dc79efcf2e61e093 /plugins/mod_bosh.lua
parent5d4b489c3c77347b9050fae4d6e01a8649817084 (diff)
parent256ab5259da1de5e24691493c0f6a26595e17208 (diff)
downloadprosody-a7b9c6de423f4f4572aaf81674903a27fbcd7c67.tar.gz
prosody-a7b9c6de423f4f4572aaf81674903a27fbcd7c67.zip
Merge 0.10->trunk
Diffstat (limited to 'plugins/mod_bosh.lua')
-rw-r--r--plugins/mod_bosh.lua4
1 files changed, 3 insertions, 1 deletions
diff --git a/plugins/mod_bosh.lua b/plugins/mod_bosh.lua
index 8d83ecd6..c2809143 100644
--- a/plugins/mod_bosh.lua
+++ b/plugins/mod_bosh.lua
@@ -308,7 +308,7 @@ function stream_callbacks.streamopened(context, attr)
-- New session
sid = new_uuid();
local session = {
- type = "c2s_unauthed", conn = {}, sid = sid, rid = rid, host = attr.to,
+ type = "c2s_unauthed", conn = request.conn, sid = sid, rid = rid, host = attr.to,
bosh_version = attr.ver, bosh_wait = wait, streamid = sid,
bosh_max_inactive = bosh_max_inactivity,
requests = { }, send_buffer = {}, reset_stream = bosh_reset_stream,
@@ -384,6 +384,8 @@ function stream_callbacks.streamopened(context, attr)
return;
end
+ session.conn = request.conn;
+
if session.rid then
local rid = tonumber(attr.rid);
local diff = rid - session.rid;