25
1
mirror of https://github.com/processone/ejabberd.git synced 2024-11-26 16:26:24 +01:00

Port #2583 from trunk

Use the local (target) domain for firing the s2s_receive_packet hook.  

It was using the external server domain (LFrom) instead of the local domain (LTo).  
This might have impact on mod_caps in s2s scenarios, needs further attention.

SVN Revision: 2584
This commit is contained in:
Pablo Polvorin 2009-09-04 21:33:30 +00:00
parent 29b2da42f5
commit 283aa52b31

View File

@ -399,7 +399,7 @@ stream_established({xmlstreamelement, El}, StateData) ->
(Name == 'presence')) -> (Name == 'presence')) ->
ejabberd_hooks:run( ejabberd_hooks:run(
s2s_receive_packet, s2s_receive_packet,
exmpp_jid:prep_domain(From), exmpp_jid:prep_domain(To),
[From, To, El]), [From, To, El]),
ejabberd_router:route( ejabberd_router:route(
From, To, El); From, To, El);
@ -419,7 +419,7 @@ stream_established({xmlstreamelement, El}, StateData) ->
(Name == 'presence')) -> (Name == 'presence')) ->
ejabberd_hooks:run( ejabberd_hooks:run(
s2s_receive_packet, s2s_receive_packet,
exmpp_jid:prep_domain(From), exmpp_jid:prep_domain(To),
[From, To, El]), [From, To, El]),
ejabberd_router:route( ejabberd_router:route(
From, To, El); From, To, El);