From b08ae0734747053a50260b0d3fc4726b021b9681 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jean-S=C3=A9bastien=20P=C3=A9dron?= Date: Tue, 1 Jul 2008 09:46:57 +0000 Subject: [PATCH] acl doesn't require conversion anymore. SVN Revision: 1399 --- src/ejabberd_c2s.erl | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/src/ejabberd_c2s.erl b/src/ejabberd_c2s.erl index 271ffabd7..8cc98e0f2 100644 --- a/src/ejabberd_c2s.erl +++ b/src/ejabberd_c2s.erl @@ -1306,10 +1306,8 @@ terminate(_Reason, StateName, StateData) -> %%%---------------------------------------------------------------------- change_shaper(StateData, JID) -> - % XXX OLD FORMAT: JIDOld is an old #jid. - JIDOld = jlib:to_old_jid(JID), Shaper = acl:match_rule(StateData#state.server, - StateData#state.shaper, JIDOld), + StateData#state.shaper, JID), (StateData#state.sockmod):change_shaper(StateData#state.socket, Shaper). send_text(StateData, Text) -> @@ -1674,10 +1672,6 @@ presence_broadcast_to_trusted(StateData, From, T, A, Packet) -> presence_broadcast_first(From, StateData, Packet) -> Probe = exmpp_presence:probe(), - % XXX OLD FORMAT: From, Packet, Probe. - FromOld = jlib:to_old_jid(From), - PacketOld = exmpp_xml:xmlel_to_xmlelement(Packet, - [?DEFAULT_NS], ?PREFIXED_NS), ?SETS:fold(fun({U, S, R}, X) -> FJID = exmpp_jid:make_jid(U, S, R), ejabberd_router:route( @@ -1695,8 +1689,11 @@ presence_broadcast_first(From, StateData, Packet) -> As = ?SETS:fold( fun({U, S, R} = JID, A) -> FJID = exmpp_jid:make_jid(U, S, R), - % XXX OLD FORMAT: FJID. + % XXX OLD FORMAT: From, FJID, Packet. + FromOld = jlib:to_old_jid(From), FJIDOld = jlib:to_old_jid(FJID), + PacketOld = exmpp_xml:xmlel_to_xmlelement(Packet, + [?DEFAULT_NS], ?PREFIXED_NS), case ejabberd_hooks:run_fold( privacy_check_packet, StateData#state.server, allow,