core/stanza_router.lua

changeset 1348
ffa70c0df850
parent 1307
c9c58aa990bb
child 1356
b760c0d4e012
equal deleted inserted replaced
1346:e34f9455b779 1348:ffa70c0df850
308 log("debug", "sending s2s stanza: %s", tostring(stanza)); 308 log("debug", "sending s2s stanza: %s", tostring(stanza));
309 send_s2s(origin.host, host, stanza); -- TODO handle remote routing errors 309 send_s2s(origin.host, host, stanza); -- TODO handle remote routing errors
310 stanza.attr.xmlns = xmlns; -- reset 310 stanza.attr.xmlns = xmlns; -- reset
311 elseif origin.type == "component" or origin.type == "local" then 311 elseif origin.type == "component" or origin.type == "local" then
312 -- Route via s2s for components and modules 312 -- Route via s2s for components and modules
313 log("debug", "Routing outgoing stanza for %s to %s", origin.host, host); 313 log("debug", "Routing outgoing stanza for %s to %s", from_host, host);
314 send_s2s(origin.host, host, stanza); 314 send_s2s(from_host, host, stanza);
315 else 315 else
316 log("warn", "received stanza from unhandled connection type: %s", origin.type); 316 log("warn", "received stanza from unhandled connection type: %s", origin.type);
317 end 317 end
318 stanza.attr.to = to; -- reset 318 stanza.attr.to = to; -- reset
319 end 319 end

mercurial