Commit 06b9c9d1 authored by Gaston Dombiak's avatar Gaston Dombiak Committed by gato

Fixed leaking of Session instances. JM-558

git-svn-id: http://svn.igniterealtime.org/svn/repos/wildfire/trunk@3391 b35dd754-fafc-0310-a699-88a17e54d16e
parent 614ff0c4
......@@ -106,6 +106,11 @@ public class PresenceUpdateHandler extends BasicModule implements ChannelHandler
else if (Presence.Type.unavailable == type) {
broadcastUpdate(presence.createCopy());
broadcastUnavailableForDirectedPresences(presence);
if (session == null) {
// Recovery logic. Check if a session can be found in the routing table.
session = (ClientSession) XMPPServer.getInstance().getRoutingTable()
.getRoute(presence.getFrom());
}
if (session != null) {
session.setPresence(presence);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment