[kdiff3] [Bug 484988] SEGABRT in Kdiff3 with Qt 6.6+ when opening files

2024-04-22 Thread michael
https://bugs.kde.org/show_bug.cgi?id=484988

--- Comment #9 from michael  ---
Go ahead and file sperrate bug for the new crash so its easier to track.

-- 
You are receiving this mail because:
You are watching all bug changes.

[kdiff3] [Bug 484988] SEGABRT in Kdiff3 with Qt 6.6+ when opening files

2024-04-22 Thread Mike Lothian
https://bugs.kde.org/show_bug.cgi?id=484988

--- Comment #8 from Mike Lothian  ---
I'm still seeing a failure on master:

(lldb) run
Process 1098029 launched: '/usr/bin/kdiff3' (x86_64)
org.kde.kdiff3: Loading A:  "/home/fireburn/dmesg.axion"
org.kde.kdiff3: Loading B:  "/home/fireburn/dmesg.txt"
org.kde.kdiff3: Diff: A <-> B
org.kde.kdiff3: Linediff: A <-> B
org.kde.kdiff3: Enter: calcDiff3LineListUsingAB
org.kde.kdiff3: Leave: calcDiff3LineListUsingAB
terminate called after throwing an instance of 'std::system_error'
  what():  converted signed value too small: negative overflow error
Process 1098029 stopped
* thread #1, name = 'kdiff3', stop reason = signal SIGABRT
frame #0: 0x762bf86c libc.so.6`___lldb_unnamed_symbol3697 + 268
libc.so.6`___lldb_unnamed_symbol3697:
->  0x762bf86c <+268>: movl   %eax, %ebx
0x762bf86e <+270>: negl   %ebx
0x762bf870 <+272>: cmpl   $0xf000, %eax ; imm = 0xF000 
0x762bf875 <+277>: movl   $0x0, %eax
(lldb) bt
* thread #1, name = 'kdiff3', stop reason = signal SIGABRT
  * frame #0: 0x762bf86c libc.so.6`___lldb_unnamed_symbol3697 + 268
frame #1: 0x7626be66 libc.so.6`raise + 22
frame #2: 0x762538b7 libc.so.6`abort + 215
frame #3: 0x758a4c7b libstdc++.so.6`___lldb_unnamed_symbol7333 + 98
frame #4: 0x758b8eec libstdc++.so.6`___lldb_unnamed_symbol7788 + 12
frame #5: 0x758b8f57 libstdc++.so.6`std::terminate() + 23
frame #6: 0x5560fabf kdiff3`__clang_call_terminate + 15
frame #7: 0x5567559f kdiff3`getBestFirstLine(LineRef, int, LineRef,
int) [inlined] LineRef::operator=(this=, lineIn=) at
LineRef.h:51:21
frame #8: 0x55675581 kdiff3`getBestFirstLine(line=LineRef @ scalar,
nofLines=1559, firstLine=LineRef @ scalar, visibleLines=14) at
difftextwindow.cpp:0
frame #9: 0x556756ab
kdiff3`DiffTextWindow::setFastSelectorRange(this=0x5615a6c0,
line1=, nofLines=) at difftextwindow.cpp:595:32
frame #10: 0x760dda8f libQt6Core.so.6`___lldb_unnamed_symbol13786 +
1279
frame #11: 0x5560ccd1
kdiff3`MergeResultWindow::setFastSelectorRange(this=, _t1=LineRef
@ 0x7fffc46c, _t2=1559) at moc_mergeresultwindow.cpp:574:5
frame #12: 0x556ad3f3
kdiff3`MergeResultWindow::setFastSelector(this=0x55c804c0,
i=std::__cxx11::list >::iterator @
scalar) at mergeresultwindow.cpp:788:12
frame #13: 0x556a63a2 kdiff3`MergeResultWindow::merge(bool,
e_SrcSelector, bool, bool) [inlined]
MergeResultWindow::go(this=0x55c804c0, eDir=eUp, eEndPoint=eEnd) at
mergeresultwindow.cpp:548:5
frame #14: 0x556a6364 kdiff3`MergeResultWindow::merge(bool,
e_SrcSelector, bool, bool) [inlined]
MergeResultWindow::slotGoTop(this=0x55c804c0) at
mergeresultwindow.cpp:658:5
frame #15: 0x556a6364
kdiff3`MergeResultWindow::merge(this=0x55c804c0,
bAutoSolve=, defaultSelector=, bConflictsOnly=false,
bWhiteSpaceOnly=) at mergeresultwindow.cpp:397:5
frame #16: 0x556a5d8c
kdiff3`MergeResultWindow::init(this=0x55c804c0,
pLineDataA=, sizeA=LineRef @ 0x7fffc5c8,
pLineDataB=, sizeB=LineRef @ 0x7fffc5cc,
pLineDataC=, sizeC=LineRef @ 0x7fffc620,
pDiff3LineList=0x5597a388, pTotalDiffStatus=0x55a9ac50,
bAutoSolve=true) at mergeresultwindow.cpp:132:5
frame #17: 0x5565f1b0
kdiff3`KDiff3App::mainInit(this=0x55979fe0,
pTotalDiffStatus=, inFlags=) at pdiff.cpp:377:27
frame #18: 0x5563193c kdiff3`KDiff3App::completeInit(QString
const&, QString const&, QString const&) [inlined]
KDiff3App::doFileCompare(this=0x55979fe0) at kdiff3.cpp:595:5
frame #19: 0x55631908
kdiff3`KDiff3App::completeInit(this=0x55979fe0, fn1=,
fn2=, fn3=) at kdiff3.cpp:646:13
frame #20: 0x5561d3e0
kdiff3`KDiff3Shell::KDiff3Shell(this=0x55a07850,
fn1=0x7fffcb68, fn2=0x7fffcb50, fn3=0x7fffcb38) at
kdiff3_shell.cpp:39:15
frame #21: 0x5561c629 kdiff3`QtPrivate::QCallableObject, void>::impl(int, QtPrivate::QSlotObjectBase*, QObject*,
void**, bool*) [inlined] main::$_0::operator()(this=0x55982d30) const
at main.cpp:192:21
frame #22: 0x5561c587 kdiff3`QtPrivate::QCallableObject, void>::impl(int, QtPrivate::QSlotObjectBase*, QObject*,
void**, bool*) [inlined] QtPrivate::FunctorCall,
QtPrivate::List<>, void, main::$_0>::call(f=0x55982d30,
arg=) at qobjectdefs_impl.h:137:13
frame #23: 0x5561c587 kdiff3`QtPrivate::QCallableObject, void>::impl(int, QtPrivate::QSlotObjectBase*, QObject*,
void**, bool*) [inlined] void
QtPrivate::FunctorCallable::call,
void>(f=0x55982d30, (null)=, arg=) at
qobjectdefs_impl.h:345:13
frame #24: 0x5561c587 kdiff3`QtPrivate::QCallableObject, void>::impl(which=, this_=0x55982d20,
r=, a=, ret=) at
qobjectdefs_impl.h:555:21
frame #25: 0x76084f6c 

[kdiff3] [Bug 484988] SEGABRT in Kdiff3 with Qt 6.6+ when opening files

2024-04-21 Thread michael
https://bugs.kde.org/show_bug.cgi?id=484988

michael  changed:

   What|Removed |Added

 Resolution|--- |FIXED
 Status|ASSIGNED|RESOLVED

--- Comment #7 from michael  ---
Both the crash and the file processing error have now been corrected in master
and 1.11.

-- 
You are receiving this mail because:
You are watching all bug changes.

[kdiff3] [Bug 484988] SEGABRT in Kdiff3 with Qt 6.6+ when opening files

2024-04-21 Thread michael
https://bugs.kde.org/show_bug.cgi?id=484988

michael  changed:

   What|Removed |Added

 Ever confirmed|0   |1
 Status|REPORTED|ASSIGNED

--- Comment #6 from michael  ---
The crash on save is fixed in:
700eb940c615d8a90632f87f9833ca1a8e3a2fc2
ff6196eba71179c528360ab5eef355989d5ae979

This is present in master and 1.11.0.

Will be submitting a fix for the file open crash shortly.

-- 
You are receiving this mail because:
You are watching all bug changes.

[kdiff3] [Bug 484988] SEGABRT in Kdiff3 with Qt 6.6+ when opening files

2024-04-10 Thread Mike Lothian
https://bugs.kde.org/show_bug.cgi?id=484988

--- Comment #5 from Mike Lothian  ---
I got a backtrace from kdiff3

 git mergetool
Merging:
kcms/mouse/CMakeLists.txt

Normal merge conflict for 'kcms/mouse/CMakeLists.txt':
  {local}: modified file
  {remote}: modified file
(lldb) target create "kdiff3"
Current executable set to '/usr/bin/kdiff3' (x86_64).
(lldb) settings set -- target.run-args  "--auto" "--L1"
"kcms/mouse/CMakeLists.txt (Base)" "--L2" "kcms/mouse/CMakeLists.txt (Local)"
"--L3" "kcms/mouse/CMakeLists.txt (Remote)" "-o" "kcms/mouse/CMakeLists.txt"
"./kcms/mouse/CMakeLists_BASE_1741404.txt"
"./kcms/mouse/CMakeLists_LOCAL_1741404.txt"
"./kcms/mouse/CMakeLists_REMOTE_1741404.txt"
(lldb) run
org.kde.kdiff3: Diff: A <-> B
org.kde.kdiff3: Linediff: A <-> B
org.kde.kdiff3: Enter: calcDiff3LineListUsingAB
org.kde.kdiff3: Leave: calcDiff3LineListUsingAB
Process 1741515 launched: '/usr/bin/kdiff3' (x86_64)
Process 1741515 stopped and restarted: thread 2 received signal: SIGCHLD
Process 1741515 stopped
* thread #1, name = 'kdiff3', stop reason = signal SIGSEGV: address not mapped
to object (fault address: 0x8)
frame #0: 0x761095b4 libQt6Core.so.6`QIODevice::isOpen() const + 4
libQt6Core.so.6`QIODevice::isOpen:
->  0x761095b4 <+4>:  movq   0x8(%rdi), %rax
0x761095b8 <+8>:  cmpl   $0x0, 0x180(%rax)
0x761095bf <+15>: setne  %al
0x761095c2 <+18>: retq
(lldb) bt
* thread #1, name = 'kdiff3', stop reason = signal SIGSEGV: address not mapped
to object (fault address: 0x8)
  * frame #0: 0x761095b4 libQt6Core.so.6`QIODevice::isOpen() const + 4
frame #1: 0x556c2d6c
kdiff3`FileAccess::writeFile(this=0x7fffc520,
pSrcBuffer=0x75d0aa80, length=0) at fileaccess.cpp:865:9
frame #2: 0x556b66d5
kdiff3`MergeResultWindow::saveDocument(this=0x56130830,
fileName=, encoding=, eLineEndStyle=) at
mergeresultwindow.cpp:2689:25
frame #3: 0x55631369
kdiff3`KDiff3App::completeInit(this=0x559aa0d0, fn1=,
fn2=, fn3=) at kdiff3.cpp:688:54
frame #4: 0x5561c3c0
kdiff3`KDiff3Shell::KDiff3Shell(this=0x5599d540,
fn1=0x7fffc948, fn2=0x7fffc930, fn3=0x7fffc918) at
kdiff3_shell.cpp:39:15
frame #5: 0x5561b609 kdiff3`QtPrivate::QCallableObject, void>::impl(int, QtPrivate::QSlotObjectBase*, QObject*,
void**, bool*) [inlined] main::$_0::operator()(this=0x55b2f600) const
at main.cpp:196:21
frame #6: 0x5561b567 kdiff3`QtPrivate::QCallableObject, void>::impl(int, QtPrivate::QSlotObjectBase*, QObject*,
void**, bool*) [inlined] QtPrivate::FunctorCall,
QtPrivate::List<>, void, main::$_0>::call(f=0x55b2f600,
arg=) at qobjectdefs_impl.h:137:13
frame #7: 0x5561b567 kdiff3`QtPrivate::QCallableObject, void>::impl(int, QtPrivate::QSlotObjectBase*, QObject*,
void**, bool*) [inlined] void
QtPrivate::FunctorCallable::call,
void>(f=0x55b2f600, (null)=, arg=) at
qobjectdefs_impl.h:345:13
frame #8: 0x5561b567 kdiff3`QtPrivate::QCallableObject, void>::impl(which=, this_=0x55b2f5f0,
r=, a=, ret=) at
qobjectdefs_impl.h:555:21
frame #9: 0x76084f6c libQt6Core.so.6`QObject::event(QEvent*) + 636
frame #10: 0x76714d47
libQt6Gui.so.6`QGuiApplication::event(QEvent*) + 711
frame #11: 0x7768d9a8
libQt6Widgets.so.6`QApplication::event(QEvent*) + 520
frame #12: 0x7769061e
libQt6Widgets.so.6`QApplicationPrivate::notify_helper(QObject*, QEvent*) + 302
frame #13: 0x776920ae
libQt6Widgets.so.6`QApplication::notify(QObject*, QEvent*) + 494
frame #14: 0x76133f57
libQt6Core.so.6`QCoreApplication::notifyInternal2(QObject*, QEvent*) + 183
frame #15: 0x7613572e
libQt6Core.so.6`QCoreApplicationPrivate::sendPostedEvents(QObject*, int,
QThreadData*) + 526
frame #16: 0x75ecb2d7 libQt6Core.so.6`___lldb_unnamed_symbol10036 +
23
frame #17: 0x74f49602 libglib-2.0.so.0`___lldb_unnamed_symbol2489 +
482
frame #18: 0x74fb6588 libglib-2.0.so.0`___lldb_unnamed_symbol2747 +
600
frame #19: 0x74f488ac libglib-2.0.so.0`g_main_context_iteration +
44
frame #20: 0x75eb61c4
libQt6Core.so.6`QEventDispatcherGlib::processEvents(QFlags)
+ 100
frame #21: 0x76134ba6
libQt6Core.so.6`QEventLoop::exec(QFlags) + 550
frame #22: 0x761347e8 libQt6Core.so.6`QCoreApplication::exec() +
136
frame #23: 0x55619a69 kdiff3`main(argc=13, argv=) at
main.cpp:199:21
frame #24: 0x76256f46 libc.so.6`___lldb_unnamed_symbol3280 + 134
frame #25: 0x76256ff9 libc.so.6`__libc_start_main + 137
frame #26: 0x556073c5 kdiff3`_start + 37

-- 
You are receiving this mail because:
You are watching all bug changes.

[kdiff3] [Bug 484988] SEGABRT in Kdiff3 with Qt 6.6+ when opening files

2024-04-03 Thread Mike Lothian
https://bugs.kde.org/show_bug.cgi?id=484988

--- Comment #4 from Mike Lothian  ---
I've just checked, without the patch kdiff still doesn't crash if launched with
"kdiff3 /path/to/filea /path/to/fileb" only when it's "kdiff3 filea fileb"

It also aborts when using git mergetool:

git revert db7606495bb81894d91617e6348825a47de785c2
Auto-merging po/tr/kdiff3.po
CONFLICT (content): Merge conflict in po/tr/kdiff3.po
error: could not revert db760649... GIT_SILENT Sync po/docbooks with svn
hint: After resolving the conflicts, mark them with
hint: "git add/rm ", then run
hint: "git revert --continue".
hint: You can instead skip this commit with "git revert --skip".
hint: To abort and get back to the state before "git revert",
hint: run "git revert --abort".
fireburn@axion ~/kdiff3 $ git mergetool
Merging:
po/tr/kdiff3.po

Normal merge conflict for 'po/tr/kdiff3.po':
  {local}: modified file
  {remote}: modified file
/usr/libexec/git-core/mergetools/kdiff3: line 11: 28298 Segmentation fault 
(core dumped) "$merge_tool_path" --auto --L1 "$MERGED (Base)" --L2 "$MERGED
(Local)" --L3 "$MERGED (Remote)" -o "$MERGED" "$BASE" "$LOCAL" "$REMOTE" >
/dev/null 2>&1
merge of po/tr/kdiff3.po failed

Which gives the following debug info:

Application: KDiff3 (kdiff3), signal: Segmentation fault

[New LWP 31172]
[New LWP 31173]
[New LWP 31177]
[New LWP 31195]
[New LWP 31180]
[New LWP 31176]
[New LWP 31194]
[New LWP 31178]
[New LWP 31197]
[New LWP 31179]
[New LWP 31196]
[New LWP 31181]
[New LWP 31175]
[New LWP 31174]
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/usr/lib64/libthread_db.so.1".
Core was generated by `kdiff3 --auto --L1 po/tr/kdiff3.po (Base) --L2
po/tr/kdiff3.po (Local) --L3 po/'.
Program terminated with signal SIGSEGV, Segmentation fault.
#0  0x7f21e9cc0b5c in ?? () from /usr/lib64/libc.so.6
[Current thread is 1 (Thread 0x7f21e5fdd9c0 (LWP 31172))]
Cannot QML trace cores :(
Unexpectedly stumbled over an objfile (/usr/bin/kdiff3) without build_id. Not
creating payload.
[Current thread is 1 (Thread 0x7f21e5fdd9c0 (LWP 31172))]

Thread 14 (Thread 0x7f21df6006c0 (LWP 31174)):
#0  0x7f21e9d213bf in poll () at /usr/lib64/libc.so.6
#1  0x7f21e8a496b8 in ??? () at /usr/lib64/libQt6WaylandClient.so.6
#2  0x7f21ea5eb09e in ??? () at /usr/lib64/libQt6Core.so.6
#3  0x7f21e9cbed22 in ??? () at /usr/lib64/libc.so.6
#4  0x7f21e9d2e63c in ??? () at /usr/lib64/libc.so.6

Thread 13 (Thread 0x7f21dec006c0 (LWP 31175)):
#0  0x7f21e9d213bf in poll () at /usr/lib64/libc.so.6
#1  0x7f21e8a496b8 in ??? () at /usr/lib64/libQt6WaylandClient.so.6
#2  0x7f21ea5eb09e in ??? () at /usr/lib64/libQt6Core.so.6
#3  0x7f21e9cbed22 in ??? () at /usr/lib64/libc.so.6
#4  0x7f21e9d2e63c in ??? () at /usr/lib64/libc.so.6

Thread 12 (Thread 0x7f21d4c006c0 (LWP 31181)):
#0  0x7f21e9cbb565 in ??? () at /usr/lib64/libc.so.6
#1  0x7f21e9cbdea1 in pthread_cond_wait () at /usr/lib64/libc.so.6
#2  0x7f21dcef7fbd in ??? () at /usr/lib64/dri/radeonsi_dri.so
#3  0x7f21dcf8485a in ??? () at /usr/lib64/dri/radeonsi_dri.so
#4  0x7f21e9cbed22 in ??? () at /usr/lib64/libc.so.6
#5  0x7f21e9d2e63c in ??? () at /usr/lib64/libc.so.6

Thread 11 (Thread 0x7f21cea006c0 (LWP 31196)):
#0  0x7f21e9cbb565 in ??? () at /usr/lib64/libc.so.6
#1  0x7f21e9cbe1f9 in pthread_cond_timedwait () at /usr/lib64/libc.so.6
#2  0x7f21ea5fb6a3 in ??? () at /usr/lib64/libQt6Core.so.6
#3  0x7f21ea5ebdf9 in QWaitCondition::wait(QMutex*, QDeadlineTimer) () at
/usr/lib64/libQt6Core.so.6
#4  0x7f21ea5efdb6 in ??? () at /usr/lib64/libQt6Core.so.6
#5  0x7f21ea5eb09e in ??? () at /usr/lib64/libQt6Core.so.6
#6  0x7f21e9cbed22 in ??? () at /usr/lib64/libc.so.6
#7  0x7f21e9d2e63c in ??? () at /usr/lib64/libc.so.6

Thread 10 (Thread 0x7f21d60006c0 (LWP 31179)):
#0  0x7f21e9cbb565 in ??? () at /usr/lib64/libc.so.6
#1  0x7f21e9cbdea1 in pthread_cond_wait () at /usr/lib64/libc.so.6
#2  0x7f21dcef7fbd in ??? () at /usr/lib64/dri/radeonsi_dri.so
#3  0x7f21dcf8485a in ??? () at /usr/lib64/dri/radeonsi_dri.so
#4  0x7f21e9cbed22 in ??? () at /usr/lib64/libc.so.6
#5  0x7f21e9d2e63c in ??? () at /usr/lib64/libc.so.6

Thread 9 (Thread 0x7f21ce0006c0 (LWP 31197)):
#0  0x7f21e9cbb565 in ??? () at /usr/lib64/libc.so.6
#1  0x7f21e9cbe1f9 in pthread_cond_timedwait () at /usr/lib64/libc.so.6
#2  0x7f21ea5fb6a3 in ??? () at /usr/lib64/libQt6Core.so.6
#3  0x7f21ea5ebdf9 in QWaitCondition::wait(QMutex*, QDeadlineTimer) () at
/usr/lib64/libQt6Core.so.6
#4  0x7f21ea5efdb6 in ??? () at /usr/lib64/libQt6Core.so.6
#5  0x7f21ea5eb09e in ??? () at /usr/lib64/libQt6Core.so.6
#6  0x7f21e9cbed22 in ??? () at /usr/lib64/libc.so.6
#7  0x7f21e9d2e63c in ??? () at /usr/lib64/libc.so.6

Thread 8 (Thread 0x7f21d6a006c0 (LWP 31178)):
#0  0x7f21e9cbb565 in ??? () at /usr/lib64/libc.so.6
#1  0x7f21e9cbdea1 in pthread_cond_wait () at 

[kdiff3] [Bug 484988] SEGABRT in Kdiff3 with Qt 6.6+ when opening files

2024-04-03 Thread Mike Lothian
https://bugs.kde.org/show_bug.cgi?id=484988

--- Comment #3 from Mike Lothian  ---
kdiff3 SQ-game8-sorted SQ-ign-sorted
org.kde.kdiff3: Loading A:  "http://sq-game8-sorted;
kf.kio.core: mimeType() not emitted when sending first data!; job URL =
QUrl("http://sq-game8-sorted;) data size = 0
org.kde.kdiff3: Loading B:  "http://sq-ign-sorted;
kf.kio.core: mimeType() not emitted when sending first data!; job URL =
QUrl("http://sq-ign-sorted;) data size = 0
org.kde.kdiff3: Diff: A <-> B
org.kde.kdiff3: Linediff: A <-> B
org.kde.kdiff3: Enter: calcDiff3LineListUsingAB
org.kde.kdiff3: Leave: calcDiff3LineListUsingAB

-- 
You are receiving this mail because:
You are watching all bug changes.

[kdiff3] [Bug 484988] SEGABRT in Kdiff3 with Qt 6.6+ when opening files

2024-04-03 Thread Mike Lothian
https://bugs.kde.org/show_bug.cgi?id=484988

--- Comment #2 from Mike Lothian  ---
So I notice this happens when running from the command line

kdiff3 filea fileb

It's assumign that filea & fileb are actually http://filea https://fileb and
saying they're binary equal

But works fine when giving the full location to the file, or opening the files
from the dialog manually

-- 
You are receiving this mail because:
You are watching all bug changes.

[kdiff3] [Bug 484988] SEGABRT in Kdiff3 with Qt 6.6+ when opening files

2024-04-03 Thread Mike Lothian
https://bugs.kde.org/show_bug.cgi?id=484988

--- Comment #1 from Mike Lothian  ---
Created attachment 168106
  --> https://bugs.kde.org/attachment.cgi?id=168106=edit
workaround

This works around the issue

-- 
You are receiving this mail because:
You are watching all bug changes.