25
1
mirror of https://github.com/processone/ejabberd.git synced 2024-12-24 17:29:28 +01:00

Stringprep JID before get_node calculation

This commit is contained in:
Evgeniy Khramtsov 2011-04-17 19:48:57 +10:00
parent 70e84021f2
commit 49365da481

View File

@ -2521,13 +2521,12 @@ peerip(SockMod, Socket) ->
maybe_migrate(StateName, StateData) -> maybe_migrate(StateName, StateData) ->
PackedStateData = pack(StateData), PackedStateData = pack(StateData),
case ejabberd_cluster:get_node({StateData#state.user, #state{user = U, server = S, resource = R, sid = SID} = StateData,
StateData#state.server}) of case ejabberd_cluster:get_node({jlib:nodeprep(U), jlib:nameprep(S)}) of
Node when Node == node() -> Node when Node == node() ->
Conn = get_conn_type(StateData), Conn = get_conn_type(StateData),
Info = [{ip, StateData#state.ip}, {conn, Conn}, Info = [{ip, StateData#state.ip}, {conn, Conn},
{auth_module, StateData#state.auth_module}], {auth_module, StateData#state.auth_module}],
#state{user = U, server = S, resource = R, sid = SID} = StateData,
Presence = StateData#state.pres_last, Presence = StateData#state.pres_last,
Priority = Priority =
case Presence of case Presence of