diff options
Diffstat (limited to 'src/base/QXmppSasl.cpp')
| -rw-r--r-- | src/base/QXmppSasl.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/base/QXmppSasl.cpp b/src/base/QXmppSasl.cpp index 8d5217fb..b045c864 100644 --- a/src/base/QXmppSasl.cpp +++ b/src/base/QXmppSasl.cpp @@ -871,7 +871,7 @@ QMap<QByteArray, QByteArray> QXmppSaslDigestMd5::parseMessage(const QByteArray & QMap<QByteArray, QByteArray> map; int startIndex = 0; int pos = 0; - while ((pos = ba.indexOf(QStringLiteral("="), startIndex)) >= 0) { + while ((pos = ba.indexOf('=', startIndex)) >= 0) { // key get name and skip equals const QByteArray key = ba.mid(startIndex, pos - startIndex).trimmed(); pos++; @@ -927,8 +927,8 @@ QByteArray QXmppSaslDigestMd5::serializeMessage(const QMap<QByteArray, QByteArra if (quote) { value.replace(QByteArrayLiteral("\\"), QByteArrayLiteral("\\\\")); value.replace(QByteArrayLiteral("\""), QByteArrayLiteral("\\\"")); - ba.append(QStringLiteral("\"") + value + QStringLiteral("\"")); - } else + ba.append(QByteArrayLiteral("\"") + value + QByteArrayLiteral("\"")); + } else ba.append(value); } return ba; |
