aboutsummaryrefslogtreecommitdiff
path: root/src/server/QXmppOutgoingServer.cpp
diff options
context:
space:
mode:
authorLinus Jahn <lnj@kaidan.im>2022-09-05 20:37:05 +0200
committerLinus Jahn <lnj@kaidan.im>2022-09-06 00:46:56 +0200
commit5f813f8a4bbe1e075daad7b3933829044befffb4 (patch)
tree20102aa665b03cfb6dfe0c6ece94938320b6430e /src/server/QXmppOutgoingServer.cpp
parent4c60b13e0b8011e4e0b093a690e939f3b23e2436 (diff)
Reformat code
Diffstat (limited to 'src/server/QXmppOutgoingServer.cpp')
-rw-r--r--src/server/QXmppOutgoingServer.cpp11
1 files changed, 7 insertions, 4 deletions
diff --git a/src/server/QXmppOutgoingServer.cpp b/src/server/QXmppOutgoingServer.cpp
index 7d47e9e5..49e6f4b2 100644
--- a/src/server/QXmppOutgoingServer.cpp
+++ b/src/server/QXmppOutgoingServer.cpp
@@ -196,8 +196,9 @@ void QXmppOutgoingServer::handleStanza(const QDomElement &stanza)
d->ready = true;
// send queued data
- for (const auto &data : std::as_const(d->dataQueue))
+ for (const auto &data : std::as_const(d->dataQueue)) {
sendData(data);
+ }
d->dataQueue.clear();
// emit signal
@@ -251,10 +252,11 @@ void QXmppOutgoingServer::setVerify(const QString &id, const QString &key)
void QXmppOutgoingServer::queueData(const QByteArray &data)
{
- if (isConnected())
+ if (isConnected()) {
sendData(data);
- else
+ } else {
d->dataQueue.append(data);
+ }
}
/// Returns the remote server's domain.
@@ -291,8 +293,9 @@ void QXmppOutgoingServer::sendDialback()
void QXmppOutgoingServer::slotSslErrors(const QList<QSslError> &errors)
{
warning("SSL errors");
- for (int i = 0; i < errors.count(); ++i)
+ for (int i = 0; i < errors.count(); ++i) {
warning(errors.at(i).errorString());
+ }
socket()->ignoreSslErrors();
}