Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Utilities
Kate
Commits
2ba40c6c
Commit
2ba40c6c
authored
Sep 01, 2022
by
Waqar Ahmed
Committed by
Christoph Cullmann
Sep 03, 2022
Browse files
Fix multi-file diff parsing
parent
e33566cd
Changes
1
Hide whitespace changes
Inline
Side-by-side
apps/lib/diffwidget.cpp
View file @
2ba40c6c
...
...
@@ -333,6 +333,15 @@ void DiffWidget::parseAndShowDiff(const QByteArray &raw)
lineNumsA
.
append
(
-
1
);
lineNumsB
.
append
(
-
1
);
// add new line
left
.
append
(
QString
());
right
.
append
(
QString
());
lineA
+=
1
;
lineB
+=
1
;
break
;
}
else
if
(
l
.
startsWith
(
QStringLiteral
(
"diff --git "
)))
{
// Start of a new file
markInlineDiffs
(
hunkChangedLinesA
,
hunkChangedLinesB
,
leftHlts
,
rightHlts
);
// add new line
left
.
append
(
QString
());
right
.
append
(
QString
());
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment