mirror of
https://github.com/moparisthebest/Conversations
synced 2024-11-24 17:52:17 -05:00
end otr session when receiving failed otr message warnings
This commit is contained in:
parent
394486b300
commit
af76ad0144
@ -177,7 +177,13 @@ public class MessageParser extends AbstractParser implements
|
|||||||
if (packet.getType() == MessagePacket.TYPE_ERROR) {
|
if (packet.getType() == MessagePacket.TYPE_ERROR) {
|
||||||
Jid from = packet.getFrom();
|
Jid from = packet.getFrom();
|
||||||
if (from != null) {
|
if (from != null) {
|
||||||
mXmppConnectionService.markMessage(account, from.toBareJid(), packet.getId(), Message.STATUS_SEND_FAILED);
|
Message message = mXmppConnectionService.markMessage(account,
|
||||||
|
from.toBareJid(),
|
||||||
|
packet.getId(),
|
||||||
|
Message.STATUS_SEND_FAILED);
|
||||||
|
if (message.getEncryption() == Message.ENCRYPTION_OTR) {
|
||||||
|
message.getConversation().endOtrIfNeeded();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user