summaryrefslogtreecommitdiff
path: root/protocols/JabberG/src/jabber_iqid.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <ghazan@miranda.im>2022-05-26 17:40:15 +0300
committerGeorge Hazan <ghazan@miranda.im>2022-05-26 17:40:15 +0300
commit91221d792fba0491750083ccae15424d71f28e61 (patch)
tree848f6db8103d6c26666c0fb48ea31e4320795815 /protocols/JabberG/src/jabber_iqid.cpp
parent9bcd634faa1089b97b7db84484d3f165739bea0a (diff)
Jabber: attempt to fix OMEMO
Diffstat (limited to 'protocols/JabberG/src/jabber_iqid.cpp')
-rw-r--r--protocols/JabberG/src/jabber_iqid.cpp11
1 files changed, 5 insertions, 6 deletions
diff --git a/protocols/JabberG/src/jabber_iqid.cpp b/protocols/JabberG/src/jabber_iqid.cpp
index 64c1c7d071..4056dca118 100644
--- a/protocols/JabberG/src/jabber_iqid.cpp
+++ b/protocols/JabberG/src/jabber_iqid.cpp
@@ -1069,14 +1069,13 @@ void CJabberProto::OnIqResultSetVcard(const TiXmlElement *iqNode, CJabberIqInfo*
SendPresence(m_iStatus, false);
}
}
+
void CJabberProto::OnIqResultGetOmemodevicelist(const TiXmlElement* iqNode, CJabberIqInfo*)
{
- auto* itemsNode = XmlGetChildByTag(iqNode, "items", "node", JABBER_FEAT_OMEMO ".devicelist");
- auto from = XmlGetAttr(iqNode, "from");
- if (itemsNode) {
- OmemoHandleDeviceList(from, itemsNode);
- return;
- }
+ if (const char *from = XmlGetAttr(iqNode, "from"))
+ if (auto *pubsubNode = XmlGetChildByTag(iqNode, "pubsub", "xmlns", JABBER_FEAT_PUBSUB))
+ if (auto *itemsNode = XmlGetChildByTag(pubsubNode, "items", "node", JABBER_FEAT_OMEMO ".devicelist"))
+ OmemoHandleDeviceList(from, itemsNode);
}
void CJabberProto::OnIqResultSetSearch(const TiXmlElement *iqNode, CJabberIqInfo*)