mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2024-12-21 08:09:35 +08:00
Ignore multiple sequential newlines in torrent creator
This commit is contained in:
parent
dec726c0ae
commit
964b321458
@ -114,12 +114,17 @@ void TorrentCreatorThread::run() {
|
||||
t.add_url_seed(seed.trimmed().toStdString());
|
||||
}
|
||||
qint32 tier = 0;
|
||||
bool newline = false;
|
||||
foreach (const QString &tracker, trackers) {
|
||||
if (tracker.isEmpty()) {
|
||||
if (newline)
|
||||
continue;
|
||||
++tier;
|
||||
newline = true;
|
||||
continue;
|
||||
}
|
||||
t.add_tracker(tracker.trimmed().toStdString(), tier);
|
||||
newline = false;
|
||||
}
|
||||
if (abort) return;
|
||||
// calculate the hash for all pieces
|
||||
|
Loading…
Reference in New Issue
Block a user