aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--core/s2smanager.lua2
-rw-r--r--plugins/mod_compression.lua4
-rw-r--r--plugins/mod_tls.lua4
3 files changed, 5 insertions, 5 deletions
diff --git a/core/s2smanager.lua b/core/s2smanager.lua
index d8ceb4ef..aba99ee0 100644
--- a/core/s2smanager.lua
+++ b/core/s2smanager.lua
@@ -389,7 +389,7 @@ function streamopened(session, attr)
local features = st.stanza("stream:features");
if session.to_host then
- hosts[session.to_host].events.fire_event("s2s-stream-features", { session = session, features = features });
+ hosts[session.to_host].events.fire_event("s2s-stream-features", { origin = session, features = features });
else
(session.log or log)("warn", "No 'to' on stream header from %s means we can't offer any features", session.from_host or "unknown host");
end
diff --git a/plugins/mod_compression.lua b/plugins/mod_compression.lua
index 725c0b63..4b1fa79f 100644
--- a/plugins/mod_compression.lua
+++ b/plugins/mod_compression.lua
@@ -34,9 +34,9 @@ module:hook("stream-features", function(event)
end);
module:hook("s2s-stream-features", function(event)
- local session, features = event.session, event.features;
+ local origin, features = event.origin, event.features;
-- FIXME only advertise compression support when TLS layer has no compression enabled
- if not session.compressed then
+ if not origin.compressed then
features:add_child(compression_stream_feature);
end
end);
diff --git a/plugins/mod_tls.lua b/plugins/mod_tls.lua
index dfc1e338..47b92d73 100644
--- a/plugins/mod_tls.lua
+++ b/plugins/mod_tls.lua
@@ -49,8 +49,8 @@ module:hook("stream-features", function(event)
end
end);
module:hook("s2s-stream-features", function(event)
- local session, features = event.session, event.features;
- if session.to_host and session.type ~= "s2sin" and session.conn.starttls then
+ local origin, features = event.origin, event.features;
+ if origin.to_host and origin.type ~= "s2sin" and origin.conn.starttls then
features:add_child(s2s_feature);
end
end);