Skip to content

Commit

Permalink
Merge pull request #1508 from comp500/fix/allow-empty-lines
Browse files Browse the repository at this point in the history
  • Loading branch information
Scrumplex committed Aug 15, 2023
2 parents 7ba1e7d + 1c3449e commit a360ddb
Showing 1 changed file with 3 additions and 8 deletions.
11 changes: 3 additions & 8 deletions launcher/LoggedProcess.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -65,14 +65,9 @@ QStringList LoggedProcess::reprocess(const QByteArray& data, QTextDecoder& decod
m_leftover_line = "";
}

#if QT_VERSION < QT_VERSION_CHECK(5, 14, 0)
auto lines = str.remove(QChar::CarriageReturn).split(QChar::LineFeed, QString::SkipEmptyParts);
#else
auto lines = str.remove(QChar::CarriageReturn).split(QChar::LineFeed, Qt::SkipEmptyParts);
#endif

if (!str.endsWith(QChar::LineFeed))
m_leftover_line = lines.takeLast();
auto lines = str.remove(QChar::CarriageReturn).split(QChar::LineFeed);

m_leftover_line = lines.takeLast();
return lines;
}

Expand Down

0 comments on commit a360ddb

Please sign in to comment.