aboutsummaryrefslogtreecommitdiff
path: root/source/QXmppPingIq.cpp
diff options
context:
space:
mode:
authorJeremy Lainé <jeremy.laine@m4x.org>2010-02-01 12:09:47 +0000
committerJeremy Lainé <jeremy.laine@m4x.org>2010-02-01 12:09:47 +0000
commit9d2948db0eb57f2087685b9e711bcef38dfa3394 (patch)
tree2741f4cd8ce5fbf0582e9b7539d010924cd7c99c /source/QXmppPingIq.cpp
parentb41ac3387971d843e9db0785d7f693d5cb828461 (diff)
downloadqxmpp-9d2948db0eb57f2087685b9e711bcef38dfa3394.tar.gz
reply to server -> client XMPP Ping (XEP-1099)
Diffstat (limited to 'source/QXmppPingIq.cpp')
-rw-r--r--source/QXmppPingIq.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/source/QXmppPingIq.cpp b/source/QXmppPingIq.cpp
index ccf34cf6..3b29139d 100644
--- a/source/QXmppPingIq.cpp
+++ b/source/QXmppPingIq.cpp
@@ -34,7 +34,8 @@ QXmppPingIq::QXmppPingIq() : QXmppIq(QXmppIq::Get)
bool QXmppPingIq::isPingIq( QDomElement &element )
{
QDomElement pingElement = element.firstChildElement("ping");
- return (pingElement.namespaceURI() == ns_ping);
+ return (element.attribute("type") == "get" &&
+ pingElement.namespaceURI() == ns_ping);
}
void QXmppPingIq::toXmlElementFromChild(QXmlStreamWriter *writer) const