aboutsummaryrefslogtreecommitdiffstats
path: root/src/eu/siacs
diff options
context:
space:
mode:
authoriNPUTmice <daniel@gultsch.de>2014-09-12 23:50:49 +0200
committeriNPUTmice <daniel@gultsch.de>2014-09-12 23:50:49 +0200
commit2127fcb90285028c056670cace7534bb9588c32b (patch)
tree626742033051977e02cfc008c20326e01884b554 /src/eu/siacs
parent8a36958b8892c78d23e11f95fa1cbf0f555120fe (diff)
parente6eef53768d6a021872a9f649aa7614d565f4f3a (diff)
Merge branch 'development' of github.com:siacs/Conversations into development
Diffstat (limited to 'src/eu/siacs')
-rw-r--r--src/eu/siacs/conversations/parser/MessageParser.java13
1 files changed, 8 insertions, 5 deletions
diff --git a/src/eu/siacs/conversations/parser/MessageParser.java b/src/eu/siacs/conversations/parser/MessageParser.java
index 534c9dea..b9fe3c15 100644
--- a/src/eu/siacs/conversations/parser/MessageParser.java
+++ b/src/eu/siacs/conversations/parser/MessageParser.java
@@ -186,11 +186,13 @@ public class MessageParser extends AbstractParser implements
int status;
String fullJid;
Element forwarded;
- if (packet.hasChild("received")) {
- forwarded = packet.findChild("received").findChild("forwarded");
+ if (packet.hasChild("received", "urn:xmpp:carbons:2")) {
+ forwarded = packet.findChild("received", "urn:xmpp:carbons:2")
+ .findChild("forwarded", "urn:xmpp:forward:0");
status = Message.STATUS_RECEIVED;
- } else if (packet.hasChild("sent")) {
- forwarded = packet.findChild("sent").findChild("forwarded");
+ } else if (packet.hasChild("sent", "urn:xmpp:carbons:2")) {
+ forwarded = packet.findChild("sent", "urn:xmpp:carbons:2")
+ .findChild("forwarded", "urn:xmpp:forward:0");
status = Message.STATUS_SEND;
} else {
return null;
@@ -392,7 +394,8 @@ public class MessageParser extends AbstractParser implements
if (message != null) {
message.markUnread();
}
- } else if (packet.hasChild("received") || (packet.hasChild("sent"))) {
+ } else if (packet.hasChild("received", "urn:xmpp:carbons:2")
+ || (packet.hasChild("sent", "urn:xmpp:carbons:2"))) {
message = this.parseCarbonMessage(packet, account);
if (message != null) {
if (message.getStatus() == Message.STATUS_SEND) {