Commit 5e407c08 authored by jkobus's avatar jkobus Committed by Jarek Kobus

Remove \r from git process output

Task-number: QTCREATORBUG-9443
Task-number: QTCREATORBUG-9448

Change-Id: I02e65eab6be5d129b605067425f6774550fbf511
Reviewed-by: Orgad Shaneh's avatarOrgad Shaneh <orgads@gmail.com>
parent f2fa59d6
......@@ -263,7 +263,7 @@ void GitDiffHandler::slotFileListReceived(const QByteArray &data)
if (m_editor.isNull())
return;
const QString fileList = m_editor->editorWidget()->codec()->toUnicode(data);
const QString fileList = m_editor->editorWidget()->codec()->toUnicode(data).remove(QLatin1Char('\r'));
QStringList fileNames = fileList.split(QLatin1Char('\n'), QString::SkipEmptyParts);
fileNames.removeDuplicates();
......@@ -355,7 +355,7 @@ void GitDiffHandler::slotFileContentsReceived(const QByteArray &data)
QMap<Revision, bool>::iterator itRevEnd
= revisions.end();
if (itRev != itRevEnd) {
const QString contents = m_editor->editorWidget()->codec()->toUnicode(data);
const QString contents = m_editor->editorWidget()->codec()->toUnicode(data).remove(QLatin1Char('\r'));
m_collectedRevisions[fileName][itRev.key()] = contents;
itRev = revisions.erase(itRev);
......
Markdown is supported
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