Fix narrowing conversions

This commit is contained in:
Jonas Kvinge
2021-10-30 02:21:29 +02:00
parent a704412dee
commit 79ac53b2d9
111 changed files with 376 additions and 373 deletions

View File

@@ -52,7 +52,7 @@ SongList AsxIniParser::Load(QIODevice *device, const QString &playlist_path, con
while (!device->atEnd()) {
QString line = QString::fromUtf8(device->readLine()).trimmed();
int equals = line.indexOf('=');
qint64 equals = line.indexOf('=');
QString key = line.left(equals).toLower();
QString value = line.mid(equals + 1);

View File

@@ -50,7 +50,7 @@ SongList ASXParser::Load(QIODevice *device, const QString &playlist_path, const
// Some playlists have unescaped & characters in URLs :(
QRegularExpression ex("(href\\s*=\\s*\")([^\"]+)\"", QRegularExpression::CaseInsensitiveOption);
int index = 0;
qint64 index = 0;
for (QRegularExpressionMatch re_match = ex.match(data, index); re_match.hasMatch(); re_match = ex.match(data, index)) {
index = re_match.capturedStart();
QString url = re_match.captured(2);

View File

@@ -53,7 +53,7 @@ SongList PLSParser::Load(QIODevice *device, const QString &playlist_path, const
while (!device->atEnd()) {
QString line = QString::fromUtf8(device->readLine()).trimmed();
int equals = line.indexOf('=');
qint64 equals = line.indexOf('=');
QString key = line.left(equals).toLower();
QString value = line.mid(equals + 1);