From 2298886f4d75adbc351b448274b39edf54da38ee Mon Sep 17 00:00:00 2001 From: David Faure Date: Fri, 9 Oct 2020 09:44:52 +0200 Subject: Enable -DQURL_NO_CAST_FROM_STRING -DQT_NO_CAST_TO_ASCII I have those always enabled, which is how I detected these issues. This avoids QUrl/QString confusions, and QString/QByteArray confusions. --- src/base/QXmppSasl.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/base/QXmppSasl.cpp') 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 QXmppSaslDigestMd5::parseMessage(const QByteArray & QMap 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