aboutsummaryrefslogtreecommitdiff
path: root/src/base/QXmppStun.cpp
diff options
context:
space:
mode:
authorJeremy Lainé <jeremy.laine@m4x.org>2015-08-24 16:45:14 +0200
committerJeremy Lainé <jeremy.laine@m4x.org>2015-08-24 17:12:21 +0200
commit5901b49b3f6b8d6f7d09678e34226a7f06311482 (patch)
tree304498131112d07a6d684ad7c744e576aea4abb6 /src/base/QXmppStun.cpp
parent5a6727b9c2600f334527ff7126202cf1f8685333 (diff)
downloadqxmpp-5901b49b3f6b8d6f7d09678e34226a7f06311482.tar.gz
don't send triggered check if one is in progress
Diffstat (limited to 'src/base/QXmppStun.cpp')
-rw-r--r--src/base/QXmppStun.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/base/QXmppStun.cpp b/src/base/QXmppStun.cpp
index 987e040f..cd51b46f 100644
--- a/src/base/QXmppStun.cpp
+++ b/src/base/QXmppStun.cpp
@@ -2204,7 +2204,9 @@ void QXmppIceComponent::handleDatagram(const QByteArray &buffer, const QHostAddr
pair->checked |= QIODevice::ReadOnly;
}
- if (!d->iceControlling && pair->state() != CandidatePair::SucceededState && !d->remoteUser.isEmpty())
+ if (!d->remoteUser.isEmpty()
+ && pair->state() != CandidatePair::InProgressState
+ && pair->state() != CandidatePair::SucceededState)
{
// send a triggered connectivity test
QXmppStunMessage message;
@@ -2213,8 +2215,6 @@ void QXmppIceComponent::handleDatagram(const QByteArray &buffer, const QHostAddr
message.setPriority(d->peerReflexivePriority);
message.setUsername(QString("%1:%2").arg(d->remoteUser, d->localUser));
message.iceControlled = d->tieBreaker;
- if (pair->transaction)
- pair->transaction->deleteLater();
pair->setState(CandidatePair::InProgressState);
pair->transaction = new QXmppStunTransaction(message, this);
}