Commit 57524485 authored by hjk's avatar hjk
Browse files

Fixes: work on QT_NO_CAST_FROM_BYTEARRAY

parent 9c80a469
...@@ -309,12 +309,12 @@ void SynchronousProcess::stdErrReady() ...@@ -309,12 +309,12 @@ void SynchronousProcess::stdErrReady()
QString SynchronousProcess::convertStdErr(const QByteArray &ba) QString SynchronousProcess::convertStdErr(const QByteArray &ba)
{ {
return QString::fromLocal8Bit(ba).remove(QLatin1Char('\r')); return QString::fromLocal8Bit(ba.constData(), ba.size()).remove(QLatin1Char('\r'));
} }
QString SynchronousProcess::convertStdOut(const QByteArray &ba) const QString SynchronousProcess::convertStdOut(const QByteArray &ba) const
{ {
QString stdOut = m_d->m_stdOutCodec ? m_d->m_stdOutCodec->toUnicode(ba) : QString::fromLocal8Bit(ba); QString stdOut = m_d->m_stdOutCodec ? m_d->m_stdOutCodec->toUnicode(ba) : QString::fromLocal8Bit(ba.constData(), ba.size());
return stdOut.remove(QLatin1Char('\r')); return stdOut.remove(QLatin1Char('\r'));
} }
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment