Bug 420771 - CRASH after try of commit to git repository
Summary: CRASH after try of commit to git repository
Status: RESOLVED FIXED
Alias: None
Product: kompare
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: Arch Linux Linux
: NOR crash
Target Milestone: ---
Assignee: Kompare developers
URL:
Keywords:
: 419689 421535 421536 (view as bug list)
Depends on:
Blocks:
 
Reported: 2020-04-29 21:22 UTC by Piotr Mierzwinski
Modified: 2020-05-14 22:10 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In: 20.04.1


Attachments
kcrash - stack trace for crashed KDevelop (33.58 KB, text/plain)
2020-04-29 21:22 UTC, Piotr Mierzwinski
Details
kcrash - stack trace for crashed KDevelop (17.21 KB, text/plain)
2020-04-29 21:23 UTC, Piotr Mierzwinski
Details
kcrash - stack trace for crashed KDevelop (31.46 KB, text/plain)
2020-04-29 21:23 UTC, Piotr Mierzwinski
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Piotr Mierzwinski 2020-04-29 21:22:15 UTC
Created attachment 128015 [details]
kcrash - stack trace for crashed KDevelop

SUMMARY
I have modified several files in my project using git repository. When I tried to do commit (RMB on root item of the project in Projects view -> Commit then KDevelop crashes.
I tried couple times even I restarted PC to be sure that this is not because of recent update, but after I started KDevelop and tried to do commit again, KDevelop just crashed.

STEPS TO REPRODUCE
1. Change in project couple files.
2. Try to do commit as I described above
3. 

OBSERVED RESULT
CRASH.
Before on half second appeared diff view.

EXPECTED RESULT
Performing commit in git repository.


SOFTWARE/OS VERSIONS
Linux/KDE Plasma: YES
(available in About System)
KDE Plasma Version: 5.18.4
KDE Frameworks Version: 5.69.0
Qt Version: 5.14.2

ADDITIONAL INFORMATION
git version 2.26.2-1

In attachment please find couple stack traces (not so detailed).
Comment 1 Piotr Mierzwinski 2020-04-29 21:23:00 UTC
Created attachment 128016 [details]
kcrash - stack trace for crashed KDevelop
Comment 2 Piotr Mierzwinski 2020-04-29 21:23:20 UTC
Created attachment 128017 [details]
kcrash - stack trace for crashed KDevelop
Comment 3 Piotr Mierzwinski 2020-05-03 23:17:36 UTC
I suppose KDevelop crashes because of diff plugin issue. I experienced crash also in case of option: "Show differences".

I experienced this crash in Antergos and KaOS.
KDevelop crashes every time when user try to do Commit or check differences (using "Show differences" option).

I'm not sure what diff application/library depends KDevelop on, so provide all what I have installed:
colordiff 1.0.18-2
diffutils 3.7-3
kdiff3 1.8.2-1
libkomparediff2 20.04.0-1
python-patiencediff 0.1.0-1
Comment 4 Milian Wolff 2020-05-05 19:51:30 UTC
indeed, seems to be a crash in kompare
Comment 5 Kevin Kofler 2020-05-05 21:11:11 UTC
Well, strictly speaking, it's a crash in libkomparediff2, KDevelop does not use the code from the kompare application (anymore). But there is no separate libkomparediff2 component, it seems.
Comment 6 Kevin Kofler 2020-05-05 21:46:50 UTC
The problem with these backtraces is that there is no debugging information for libkomparediff2 installed, so I do not see line numbers nor other details.
Comment 7 Piotr Mierzwinski 2020-05-05 21:53:03 UTC
(In reply to Kevin Kofler from comment #6)
> The problem with these backtraces is that there is no debugging information
> for libkomparediff2 installed, so I do not see line numbers nor other
> details.

If you are able to identify issue and fix it, I'll try to provide more detailed backtrace, so I will install libkomparediff2 with debug information.

Thanks for quick response.
Comment 8 Kevin Kofler 2020-05-05 21:56:59 UTC
I cannot promise that I will be able to fix it (especially without having access to a reproducer), but the chance that I will be able to find what is wrong will be higher if I know the exact line where it crashes.
Comment 9 Friedrich W. H. Kossebau 2020-05-06 14:22:35 UTC
Also hitting here. Seems a regression due to https://phabricator.kde.org/D27937? which ports from QLinkedList to QList, thus uncovering some broken iteration going past the end of the list (which does not crash with QLinkedList as there the iterator goes to first node if going past end node, so still pointing to list items, other than QList iterator).

Looking into fixing this myself currently, hopefully in time for 20.04.01.
Comment 10 Friedrich W. H. Kossebau 2020-05-06 20:11:03 UTC
Git commit 759183c4bc9ed26eff9426862eece835a2aee106 by Friedrich W. H. Kossebau.
Committed on 06/05/2020 at 20:10.
Pushed by kossebau into branch 'release/20.04'.

Do not crash if real files have less lines than what the patch claims
FIXED-IN: 20.04.1

M  +3    -2    komparemodellist.cpp

https://commits.kde.org/libkomparediff2/759183c4bc9ed26eff9426862eece835a2aee106
Comment 11 Friedrich W. H. Kossebau 2020-05-14 22:08:43 UTC
*** Bug 419689 has been marked as a duplicate of this bug. ***
Comment 12 Friedrich W. H. Kossebau 2020-05-14 22:09:17 UTC
*** Bug 421535 has been marked as a duplicate of this bug. ***
Comment 13 Friedrich W. H. Kossebau 2020-05-14 22:10:55 UTC
*** Bug 421536 has been marked as a duplicate of this bug. ***