Application: kate (3.4.0) KDE Platform Version: 4.4.00 (KDE 4.4.0) Qt Version: 4.6.1 Operating System: Linux 2.6.32.7-37.fc12.x86_64 x86_64 Distribution: "Fedora release 12 (Constantine)" -- Information about the crash: I opened a file, selected several lines at the end of the document and pressed Backspace to remove them, and Kate blew up in my face. Reproducably. I'm going to attach the file and point out extent of the text selection. The crash can be reproduced every time. -- Backtrace: Application: Kate (kate), signal: Segmentation fault 82 T_PSEUDO (SYSCALL_SYMBOL, SYSCALL_NAME, SYSCALL_NARGS) [Current thread is 1 (Thread 0x7f6a3dbec840 (LWP 2685))] Thread 2 (Thread 0x7f6a35abd710 (LWP 2686)): #0 pthread_cond_wait@@GLIBC_2.3.2 () at ../nptl/sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S:162 #1 0x0000003280f273e6 in QTWTF::TCMalloc_PageHeap::scavengerThread (this=0x3281200b20) at ../3rdparty/javascriptcore/JavaScriptCore/wtf/FastMalloc.cpp:2304 #2 0x0000003280f27429 in QTWTF::TCMalloc_PageHeap::runScavengerThread (context=0x328120ebec) at ../3rdparty/javascriptcore/JavaScriptCore/wtf/FastMalloc.cpp:1438 #3 0x000000374ac06a3a in start_thread (arg=<value optimized out>) at pthread_create.c:297 #4 0x000000374a0de67d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:112 #5 0x0000000000000000 in ?? () Thread 1 (Thread 0x7f6a3dbec840 (LWP 2685)): [KCrash Handler] #5 KateLineLayout::viewLineCount (this=0x0) at /usr/src/debug/kdelibs-4.4.0/kate/render/katelinelayout.cpp:173 #6 0x00007f6a35ba278a in KateLayoutCache::viewLine (this=0x34c16d0, realCursor=...) at /usr/src/debug/kdelibs-4.4.0/kate/render/katelayoutcache.cpp:395 #7 0x00007f6a35ba2d71 in KateLayoutCache::textLayout (this=0x34c16d0, realCursor=...) at /usr/src/debug/kdelibs-4.4.0/kate/render/katelayoutcache.cpp:337 #8 0x00007f6a35c00eaf in KateViewInternal::makeVisible (this=0x34c0da0, c=<value optimized out>, endCol=<value optimized out>, force=false, center=<value optimized out>, calledExternally=<value optimized out>) at /usr/src/debug/kdelibs-4.4.0/kate/view/kateviewinternal.cpp:690 #9 0x00007f6a35c01569 in KateViewInternal::updateCursor (this=0x34c0da0, newCursor=<value optimized out>, force=<value optimized out>, center=false, calledExternally=<value optimized out>) at /usr/src/debug/kdelibs-4.4.0/kate/view/kateviewinternal.cpp:1912 #10 0x00007f6a35c02149 in KateViewInternal::editEnd (this=0x34c0da0, editTagLineStart=<value optimized out>, editTagLineEnd=<value optimized out>, tagFrom=<value optimized out>) at /usr/src/debug/kdelibs-4.4.0/kate/view/kateviewinternal.cpp:3397 #11 0x00007f6a35b645e1 in KateDocument::editEnd (this=0x2847b00) at /usr/src/debug/kdelibs-4.4.0/kate/document/katedocument.cpp:981 #12 0x00007f6a35b6b260 in KateDocument::removeText (this=0x2847b00, _range=<value optimized out>, block=<value optimized out>) at /usr/src/debug/kdelibs-4.4.0/kate/document/katedocument.cpp:825 #13 0x00007f6a35b6cdaa in KateDocument::backspace (this=0x2847b00, view=<value optimized out>, c=<value optimized out>) at /usr/src/debug/kdelibs-4.4.0/kate/document/katedocument.cpp:2893 #14 0x00007f6a35bea13c in KateView::backspace (this=0x34bd050) at /usr/src/debug/kdelibs-4.4.0/kate/view/kateview.cpp:2296 #15 0x00007f6a35bee81d in KateView::qt_metacall (this=0x34bd050, _c=InvokeMetaMethod, _id=51, _a=0x7fff60c18ee0) at /usr/src/debug/kdelibs-4.4.0/x86_64-redhat-linux-gnu/kate/kateview.moc:373 #16 0x0000003276568adf in QMetaObject::activate (sender=0x357fde0, m=<value optimized out>, local_signal_index=<value optimized out>, argv=0x7fff60c18ee0) at kernel/qobject.cpp:3275 #17 0x0000003276fa59e2 in QAction::triggered (this=<value optimized out>, _t1=false) at .moc/release-shared/moc_qaction.cpp:263 #18 0x0000003276fa711b in QAction::activate (this=0x357fde0, event=<value optimized out>) at kernel/qaction.cpp:1251 #19 0x0000003276fa81d7 in QAction::event (this=<value optimized out>, e=<value optimized out>) at kernel/qaction.cpp:1177 #20 0x000000348794becd in KAction::event (this=<value optimized out>, event=0x7fff60c19550) at /usr/src/debug/kdelibs-4.4.0/kdeui/actions/kaction.cpp:129 #21 0x0000003276faa86c in QApplicationPrivate::notify_helper (this=0x25c79e0, receiver=0x357fde0, e=0x7fff60c19550) at kernel/qapplication.cpp:4298 #22 0x0000003276fb093b in QApplication::notify (this=<value optimized out>, receiver=0x357fde0, e=0x7fff60c19550) at kernel/qapplication.cpp:4181 #23 0x0000003487a067f6 in KApplication::notify (this=0x7fff60c1ab90, receiver=0x357fde0, event=0x7fff60c19550) at /usr/src/debug/kdelibs-4.4.0/kdeui/kernel/kapplication.cpp:302 #24 0x000000327655696c in QCoreApplication::notifyInternal (this=0x7fff60c1ab90, receiver=0x357fde0, event=0x7fff60c19550) at kernel/qcoreapplication.cpp:704 #25 0x0000003276fdd926 in sendEvent (this=<value optimized out>, e=0x7fff60c19b50) at ../../src/corelib/kernel/qcoreapplication.h:215 #26 QShortcutMap::dispatchEvent (this=<value optimized out>, e=0x7fff60c19b50) at kernel/qshortcutmap.cpp:879 #27 0x0000003276fdf7d7 in QShortcutMap::tryShortcutEvent (this=0x25c7b08, o=<value optimized out>, e=0x7fff60c19b50) at kernel/qshortcutmap.cpp:364 #28 0x0000003276fb2463 in QApplication::notify (this=0x7fff60c1ab90, receiver=0x34c0da0, e=0x7fff60c19b50) at kernel/qapplication.cpp:3744 #29 0x0000003487a067f6 in KApplication::notify (this=0x7fff60c1ab90, receiver=0x34c0da0, event=0x7fff60c19b50) at /usr/src/debug/kdelibs-4.4.0/kdeui/kernel/kapplication.cpp:302 #30 0x000000327655696c in QCoreApplication::notifyInternal (this=0x7fff60c1ab90, receiver=0x34c0da0, event=0x7fff60c19b50) at kernel/qcoreapplication.cpp:704 #31 0x000000327704426a in QKeyMapper::sendKeyEvent (keyWidget=0x34c0da0, grab=<value optimized out>, type=KeyPress, code=16777219, modifiers=<value optimized out>, text=..., autorepeat=<value optimized out>, count=<value optimized out>, nativeScanCode=<value optimized out>, nativeVirtualKey=<value optimized out>, nativeModifiers=<value optimized out>) at kernel/qkeymapper_x11.cpp:1861 #32 0x0000003277046680 in QKeyMapperPrivate::translateKeyEvent (this=<value optimized out>, keyWidget=0x34c0da0, event=<value optimized out>, grab=<value optimized out>) at kernel/qkeymapper_x11.cpp:1831 #33 0x0000003277020844 in QApplication::x11ProcessEvent (this=<value optimized out>, event=0x7fff60c1a720) at kernel/qapplication_x11.cpp:3394 #34 0x00000032770496b2 in x11EventSourceDispatch (s=0x25c99a0, callback=<value optimized out>, user_data=<value optimized out>) at kernel/qguieventdispatcher_glib.cpp:146 #35 0x000000327503920e in g_main_context_dispatch () from /lib64/libglib-2.0.so.0 #36 0x000000327503cbf8 in ?? () from /lib64/libglib-2.0.so.0 #37 0x000000327503cd1a in g_main_context_iteration () from /lib64/libglib-2.0.so.0 #38 0x000000327657c2b3 in QEventDispatcherGlib::processEvents (this=0x25a2030, flags=<value optimized out>) at kernel/qeventdispatcher_glib.cpp:412 #39 0x000000327704937e in QGuiEventDispatcherGlib::processEvents (this=<value optimized out>, flags=<value optimized out>) at kernel/qguieventdispatcher_glib.cpp:204 #40 0x00000032765553b2 in QEventLoop::processEvents (this=<value optimized out>, flags=...) at kernel/qeventloop.cpp:149 #41 0x000000327655567c in QEventLoop::exec (this=0x7fff60c1aa50, flags=...) at kernel/qeventloop.cpp:201 #42 0x0000003276557969 in QCoreApplication::exec () at kernel/qcoreapplication.cpp:981 #43 0x0000003489205b9d in kdemain (argc=<value optimized out>, argv=<value optimized out>) at /usr/src/debug/kdesdk-4.4.0/kate/app/katemain.cpp:377 #44 0x000000374a01eb1d in __libc_start_main (main=<value optimized out>, argc=<value optimized out>, ubp_av=<value optimized out>, init=<value optimized out>, fini=<value optimized out>, rtld_fini=<value optimized out>, stack_end=<value optimized out>) at libc-start.c:226 #45 0x00000000004006c9 in _start () Possible duplicates by query: bug 224373, bug 223985, bug 223583, bug 223345, bug 219853. Reported using DrKonqi
Created attachment 40698 [details] File involved in crash Select from the end upwards until the selection includes the "--- snip ---" line, then press Backspace -> kaboom.
What kind of mode (i.e. indentation / folding / syntax highlighting) did you assign to the file? I could not reproduce the crash, please be more specific.
I did nothing manually, I just opened the file by double-clicking in Dolphin. Mode: Tools -> Mode says "Normal". Indentation: Tools -> Indentation says "None". Folding: Folding markersd are disabled in the GUI (and thus nothing is folded). Syntax highlighting: Tools -> Highlighting says "None". Encoding: Tools -> Encoding says Utf-8. Line endings: Tools -> End of Line says UNIX.
How much of the file can you see when you open Kate? And you select just to the start of line 33 (i.e. just before the ---) or do you select the \n before (i.e. to the start of line 32? Do you delete with Backspace or with Delete? Do you select from start to end? From end to start? Sorry that I bug you with so many questions, but I just can't reproduce the crash (and boy, would I like to do so... a reproduced bug is nearly a fixed bug ;-)).
It's ok, though I have answered some of these questions in my initial report already ;). I can see all rows, but not all columns (word wrapping is disabled, so some of the long ones extend beyond the confines of the viewport). I select from the end/bottom to the start/upwards. I select to the start of line 33. I delete with backspace.
I still cannot reproduce, anyone else?
Actually, it turns out that my bug report was incomplete, mea culpa. Kate does not crash after selecting from the end to the start of line 33 and pressing backspace - rather it crashes if I press backspace twice. I.e. select from the end to the start of line 33, press backspace, press backspace again.
Thanks, this did the "trick", I reproduced it easily now.
changing status
*** Bug 223345 has been marked as a duplicate of this bug. ***
SVN commit 1090734 by cullmann: BUG: 226409 try to remove segfault, now the smartrangegroups overlap in strange ways but otherwise just the wrong group got resized, its end didnt match reality and cursors belonged to groups with end lines < cursor line M +39 -3 katesmartmanager.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=1090734
*** Bug 226322 has been marked as a duplicate of this bug. ***
*** Bug 192606 has been marked as a duplicate of this bug. ***
*** Bug 228980 has been marked as a duplicate of this bug. ***
*** Bug 230001 has been marked as a duplicate of this bug. ***
It would be great to have that in 4.4.2 or 4.4.3, because of the crash it causes, which in daily work with Kate becomes very annoying.
*** Bug 231425 has been marked as a duplicate of this bug. ***
*** Bug 233081 has been marked as a duplicate of this bug. ***
*** Bug 234335 has been marked as a duplicate of this bug. ***
*** Bug 234364 has been marked as a duplicate of this bug. ***
*** Bug 234382 has been marked as a duplicate of this bug. ***
Christoph, given this crash seems to appear very often, maybe we should consider backporting this one-liner? It's not really safe, but still seems to work...
*** Bug 235199 has been marked as a duplicate of this bug. ***
*** Bug 236041 has been marked as a duplicate of this bug. ***
*** Bug 237002 has been marked as a duplicate of this bug. ***
Just backport then please, have no checkout here for branch stuff :/ I don't know why my change works btw. and let all praise that KDE 4.5 just doesn't use smart for any kate internal stuff ;) (uh oh, beside completion, this must still be fixed)
*** Bug 237966 has been marked as a duplicate of this bug. ***
*** Bug 238394 has been marked as a duplicate of this bug. ***
*** Bug 238292 has been marked as a duplicate of this bug. ***
Please backport this fix to 4.4.4 or 4.4.5 at least. Kate crashing in the middle of editing a file is horrible by itself. If several files are open which were not saved a while its even worse. I had two crashes during the last two days.
SVN commit 1131228 by cullmann: backport fix for 226409 wrong stuff in smart leads to random segfault BUG: 226409 this is a stupid and ugly workaround M +3 -1 katesmartmanager.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=1131228
*** Bug 233224 has been marked as a duplicate of this bug. ***
*** Bug 238887 has been marked as a duplicate of this bug. ***
*** Bug 241213 has been marked as a duplicate of this bug. ***
*** Bug 242205 has been marked as a duplicate of this bug. ***
*** Bug 238704 has been marked as a duplicate of this bug. ***
*** Bug 243604 has been marked as a duplicate of this bug. ***
*** Bug 257510 has been marked as a duplicate of this bug. ***
*** Bug 256452 has been marked as a duplicate of this bug. ***
*** Bug 255585 has been marked as a duplicate of this bug. ***
*** Bug 254587 has been marked as a duplicate of this bug. ***
*** Bug 254525 has been marked as a duplicate of this bug. ***
*** Bug 259857 has been marked as a duplicate of this bug. ***
*** Bug 260996 has been marked as a duplicate of this bug. ***