aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristian Schneppe <christian@pix-art.de>2019-07-01 08:47:00 +0200
committerChristian Schneppe <christian@pix-art.de>2019-07-01 08:47:00 +0200
commit6086d9c45fe88183ae0e4c1ec2e5c316a281f028 (patch)
tree58fddc7045d0ed6a0f5ae4c3a421f32e1dd34022
parent686c4da2b0952973c736073826a580c276b10f87 (diff)
include remote server errors in errors that should trigger a self ping
-rw-r--r--src/main/java/de/pixart/messenger/parser/MessageParser.java6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/main/java/de/pixart/messenger/parser/MessageParser.java b/src/main/java/de/pixart/messenger/parser/MessageParser.java
index 5bca3e60f..b3bcc504a 100644
--- a/src/main/java/de/pixart/messenger/parser/MessageParser.java
+++ b/src/main/java/de/pixart/messenger/parser/MessageParser.java
@@ -358,12 +358,12 @@ public class MessageParser extends AbstractParser implements OnMessagePacketRece
Message.STATUS_SEND_FAILED,
extractErrorMessage(packet));
final Element error = packet.findChild("error");
- final boolean notAcceptable = error != null && error.hasChild("not-acceptable");
- if (notAcceptable) {
+ final boolean pingWorthyError = error != null && (error.hasChild("not-acceptable") || error.hasChild("remote-server-timeout") || error.hasChild("remote-server-not-found"));
+ if (pingWorthyError) {
Conversation conversation = mXmppConnectionService.find(account, from);
if (conversation != null && conversation.getMode() == Conversational.MODE_MULTI) {
if (conversation.getMucOptions().online()) {
- Log.d(Config.LOGTAG, account.getJid().asBareJid() + ": received not-acceptable error for seemingly online muc at " + from);
+ Log.d(Config.LOGTAG, account.getJid().asBareJid() + ": received ping worthy error for seemingly online muc at " + from);
mXmppConnectionService.mucSelfPingAndRejoin(conversation);
}
}