XMPP: reconnect to server, if connection is broken.

This commit is contained in:
snowleo 2011-08-08 16:03:00 +02:00
parent b9fc6a0b2b
commit 8185b05b5d

View File

@ -68,6 +68,10 @@ public class XMPPManager extends Handler implements MessageListener, ChatManager
}
if (chat != null)
{
if (!connection.isConnected()) {
disconnect();
connect();
}
chat.sendMessage(message.replaceAll("§[0-9a-f]", ""));
return true;
}