aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorAndreas Straub <andy@strb.org>2015-08-26 20:51:18 +0200
committerAndreas Straub <andy@strb.org>2015-08-26 20:52:44 +0200
commit1156ccbce2f9fa5a7b86a4caec8591ef8e2e6633 (patch)
tree08e436e69f92e9cb85a11bbd44da04099ae51af1 /src
parentcd451856b2e15bad36a9729c70947210703031c3 (diff)
Fix error handling for announce check retrieval
Only aborts when a timeout was received. Error conditions (most notably item-not-found) are interpreted as no other devices existing.
Diffstat (limited to 'src')
-rw-r--r--src/main/java/eu/siacs/conversations/crypto/axolotl/AxolotlService.java6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/main/java/eu/siacs/conversations/crypto/axolotl/AxolotlService.java b/src/main/java/eu/siacs/conversations/crypto/axolotl/AxolotlService.java
index 17d911b4..2ce62c9a 100644
--- a/src/main/java/eu/siacs/conversations/crypto/axolotl/AxolotlService.java
+++ b/src/main/java/eu/siacs/conversations/crypto/axolotl/AxolotlService.java
@@ -323,14 +323,14 @@ public class AxolotlService {
mXmppConnectionService.sendIqPacket(account, packet, new OnIqPacketReceived() {
@Override
public void onIqPacketReceived(Account account, IqPacket packet) {
- if (packet.getType() == IqPacket.TYPE.RESULT) {
+ if (packet.getType() == IqPacket.TYPE.TIMEOUT) {
+ Log.d(Config.LOGTAG, getLogprefix(account) + "Timeout received while retrieving own Device Ids.");
+ } else {
Element item = mXmppConnectionService.getIqParser().getItem(packet);
Set<Integer> deviceIds = mXmppConnectionService.getIqParser().deviceIds(item);
if (!deviceIds.contains(getOwnDeviceId())) {
publishOwnDeviceId(deviceIds);
}
- } else {
- Log.d(Config.LOGTAG, getLogprefix(account) + "Error received while retrieving Device Ids" + packet.findChild("error"));
}
}
});