Application: kate (3.8.0) KDE Platform Version: 4.8.00 (4.8.0 Qt Version: 4.8.0 Operating System: Linux 3.2.6-3.fc16.x86_64 x86_64 Distribution: "Fedora release 16 (Verne)" -- Information about the crash: I can consistently crash Kate when editing an unfinished (soon to be attached) docbook file. It might be related to the unclosed XML tag I was correcting at the time. Guess I'll have to fix it up in vim, which feels...dirty. ;-) To reproduce it, scroll down to the bottom where the unclosed XML tag around Margins is, and type a couple characters before "Margins". Sorry about the missing symbols, I'd rather get this done than download 1G worth of debuginfos ATM. Let me know if I need to retrace it. The crash can be reproduced every time. -- Backtrace: Application: Kate (kate), signal: Segmentation fault Using host libthread_db library "/lib64/libthread_db.so.1". [Current thread is 1 (Thread 0x7f36310c8840 (LWP 12746))] Thread 3 (Thread 0x7f36239fe700 (LWP 12747)): #0 0x0000003ce26e6af3 in poll () from /lib64/libc.so.6 #1 0x0000003ce4644fd8 in ?? () from /lib64/libglib-2.0.so.0 #2 0x0000003ce464549c in g_main_context_iteration () from /lib64/libglib-2.0.so.0 #3 0x0000003cecfa7dc6 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib64/libQtCore.so.4 #4 0x0000003cecf78182 in QEventLoop::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib64/libQtCore.so.4 #5 0x0000003cecf783d7 in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib64/libQtCore.so.4 #6 0x0000003cece78b27 in QThread::exec() () from /usr/lib64/libQtCore.so.4 #7 0x0000003cecf57e7f in ?? () from /usr/lib64/libQtCore.so.4 #8 0x0000003cece7bb6b in ?? () from /usr/lib64/libQtCore.so.4 #9 0x0000003ce3207d90 in start_thread () from /lib64/libpthread.so.0 #10 0x0000003ce26ef48d in clone () from /lib64/libc.so.6 Thread 2 (Thread 0x7f36230f6700 (LWP 12748)): #0 0x0000003ce320baef in pthread_cond_wait@@GLIBC_2.3.2 () from /lib64/libpthread.so.0 #1 0x0000003d02b84e62 in ?? () from /usr/lib64/libQtScript.so.4 #2 0x0000003d02b84e99 in ?? () from /usr/lib64/libQtScript.so.4 #3 0x0000003ce3207d90 in start_thread () from /lib64/libpthread.so.0 #4 0x0000003ce26ef48d in clone () from /lib64/libc.so.6 Thread 1 (Thread 0x7f36310c8840 (LWP 12746)): [KCrash Handler] #6 0x00007f3624891c78 in KateCodeFoldingTree::getLineInfo(KateLineInfo*, int) const () from /usr/lib64/libkatepartinterfaces.so.4 #7 0x00007f36248bdffa in ?? () from /usr/lib64/libkatepartinterfaces.so.4 #8 0x0000003cef619fdc in QWidget::event(QEvent*) () from /usr/lib64/libQtGui.so.4 #9 0x0000003cef5c9994 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /usr/lib64/libQtGui.so.4 #10 0x0000003cef5ce813 in QApplication::notify(QObject*, QEvent*) () from /usr/lib64/libQtGui.so.4 #11 0x0000003cf2e50eb6 in KApplication::notify(QObject*, QEvent*) () from /usr/lib64/libkdeui.so.5 #12 0x0000003cecf7904c in QCoreApplication::notifyInternal(QObject*, QEvent*) () from /usr/lib64/libQtCore.so.4 #13 0x0000003cef615c80 in QWidgetPrivate::drawWidget(QPaintDevice*, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/lib64/libQtGui.so.4 #14 0x0000003cef6168ef in QWidgetPrivate::paintSiblingsRecursive(QPaintDevice*, QList<QObject*> const&, int, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/lib64/libQtGui.so.4 #15 0x0000003cef616675 in QWidgetPrivate::paintSiblingsRecursive(QPaintDevice*, QList<QObject*> const&, int, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/lib64/libQtGui.so.4 #16 0x0000003cef616675 in QWidgetPrivate::paintSiblingsRecursive(QPaintDevice*, QList<QObject*> const&, int, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/lib64/libQtGui.so.4 #17 0x0000003cef616675 in QWidgetPrivate::paintSiblingsRecursive(QPaintDevice*, QList<QObject*> const&, int, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/lib64/libQtGui.so.4 #18 0x0000003cef616675 in QWidgetPrivate::paintSiblingsRecursive(QPaintDevice*, QList<QObject*> const&, int, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/lib64/libQtGui.so.4 #19 0x0000003cef616675 in QWidgetPrivate::paintSiblingsRecursive(QPaintDevice*, QList<QObject*> const&, int, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/lib64/libQtGui.so.4 #20 0x0000003cef6159dc in QWidgetPrivate::drawWidget(QPaintDevice*, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/lib64/libQtGui.so.4 #21 0x0000003cef6168ef in QWidgetPrivate::paintSiblingsRecursive(QPaintDevice*, QList<QObject*> const&, int, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/lib64/libQtGui.so.4 #22 0x0000003cef6159dc in QWidgetPrivate::drawWidget(QPaintDevice*, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/lib64/libQtGui.so.4 #23 0x0000003cef6168ef in QWidgetPrivate::paintSiblingsRecursive(QPaintDevice*, QList<QObject*> const&, int, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/lib64/libQtGui.so.4 #24 0x0000003cef6159dc in QWidgetPrivate::drawWidget(QPaintDevice*, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/lib64/libQtGui.so.4 #25 0x0000003cef6168ef in QWidgetPrivate::paintSiblingsRecursive(QPaintDevice*, QList<QObject*> const&, int, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/lib64/libQtGui.so.4 #26 0x0000003cef616675 in QWidgetPrivate::paintSiblingsRecursive(QPaintDevice*, QList<QObject*> const&, int, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/lib64/libQtGui.so.4 #27 0x0000003cef6159dc in QWidgetPrivate::drawWidget(QPaintDevice*, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/lib64/libQtGui.so.4 #28 0x0000003cef6168ef in QWidgetPrivate::paintSiblingsRecursive(QPaintDevice*, QList<QObject*> const&, int, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/lib64/libQtGui.so.4 #29 0x0000003cef6159dc in QWidgetPrivate::drawWidget(QPaintDevice*, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/lib64/libQtGui.so.4 #30 0x0000003cef6168ef in QWidgetPrivate::paintSiblingsRecursive(QPaintDevice*, QList<QObject*> const&, int, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/lib64/libQtGui.so.4 #31 0x0000003cef6159dc in QWidgetPrivate::drawWidget(QPaintDevice*, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/lib64/libQtGui.so.4 #32 0x0000003cef6168ef in QWidgetPrivate::paintSiblingsRecursive(QPaintDevice*, QList<QObject*> const&, int, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/lib64/libQtGui.so.4 #33 0x0000003cef6159dc in QWidgetPrivate::drawWidget(QPaintDevice*, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/lib64/libQtGui.so.4 #34 0x0000003cef6168ef in QWidgetPrivate::paintSiblingsRecursive(QPaintDevice*, QList<QObject*> const&, int, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/lib64/libQtGui.so.4 #35 0x0000003cef6159dc in QWidgetPrivate::drawWidget(QPaintDevice*, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/lib64/libQtGui.so.4 #36 0x0000003cef6168ef in QWidgetPrivate::paintSiblingsRecursive(QPaintDevice*, QList<QObject*> const&, int, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/lib64/libQtGui.so.4 #37 0x0000003cef6159dc in QWidgetPrivate::drawWidget(QPaintDevice*, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/lib64/libQtGui.so.4 #38 0x0000003cef6168ef in QWidgetPrivate::paintSiblingsRecursive(QPaintDevice*, QList<QObject*> const&, int, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/lib64/libQtGui.so.4 #39 0x0000003cef6159dc in QWidgetPrivate::drawWidget(QPaintDevice*, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/lib64/libQtGui.so.4 #40 0x0000003cef6168ef in QWidgetPrivate::paintSiblingsRecursive(QPaintDevice*, QList<QObject*> const&, int, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/lib64/libQtGui.so.4 #41 0x0000003cef616675 in QWidgetPrivate::paintSiblingsRecursive(QPaintDevice*, QList<QObject*> const&, int, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/lib64/libQtGui.so.4 #42 0x0000003cef6159dc in QWidgetPrivate::drawWidget(QPaintDevice*, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/lib64/libQtGui.so.4 #43 0x0000003cef7e1cd0 in ?? () from /usr/lib64/libQtGui.so.4 #44 0x0000003cef60c440 in QWidgetPrivate::syncBackingStore() () from /usr/lib64/libQtGui.so.4 #45 0x0000003cef61a4fc in QWidget::event(QEvent*) () from /usr/lib64/libQtGui.so.4 #46 0x0000003cef9eb54b in QMainWindow::event(QEvent*) () from /usr/lib64/libQtGui.so.4 #47 0x0000003cf2f4c5b8 in KXmlGuiWindow::event(QEvent*) () from /usr/lib64/libkdeui.so.5 #48 0x0000003cef5c9994 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /usr/lib64/libQtGui.so.4 #49 0x0000003cef5ce813 in QApplication::notify(QObject*, QEvent*) () from /usr/lib64/libQtGui.so.4 #50 0x0000003cf2e50eb6 in KApplication::notify(QObject*, QEvent*) () from /usr/lib64/libkdeui.so.5 #51 0x0000003cecf7904c in QCoreApplication::notifyInternal(QObject*, QEvent*) () from /usr/lib64/libQtCore.so.4 #52 0x0000003cecf7cada in QCoreApplicationPrivate::sendPostedEvents(QObject*, int, QThreadData*) () from /usr/lib64/libQtCore.so.4 #53 0x0000003cecfa7933 in ?? () from /usr/lib64/libQtCore.so.4 #54 0x0000003ce4644acd in g_main_context_dispatch () from /lib64/libglib-2.0.so.0 #55 0x0000003ce46452c8 in ?? () from /lib64/libglib-2.0.so.0 #56 0x0000003ce464549c in g_main_context_iteration () from /lib64/libglib-2.0.so.0 #57 0x0000003cecfa7d5f in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib64/libQtCore.so.4 #58 0x0000003cef66c66e in ?? () from /usr/lib64/libQtGui.so.4 #59 0x0000003cecf78182 in QEventLoop::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib64/libQtCore.so.4 #60 0x0000003cecf783d7 in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib64/libQtCore.so.4 #61 0x0000003cecf7cdd5 in QCoreApplication::exec() () from /usr/lib64/libQtCore.so.4 #62 0x0000003cf0c0608d in kdemain () from /usr/lib64/libkdeinit4_kate.so #63 0x0000003ce262169d in __libc_start_main () from /lib64/libc.so.6 #64 0x0000000000400761 in _start () Possible duplicates by query: bug 292921, bug 287291, bug 287204, bug 282416. Reported using DrKonqi
Created attachment 68848 [details] file that causes the crash
#7 0xb36563b2 in QVector<KateCodeFoldingNode*>::isEmpty (this=0x8ab0a54) at /usr/include/QtCore/qvector.h:139 #8 0xb3656184 in KateCodeFoldingNode::noEndChildren (this=0x8ab0a30) at /home/dh/kde/trunk/kate/part/syntax/katecodefolding.h:197 #9 0xb3656237 in KateCodeFoldingNode::hasMatch (this=0x8ab0a30) at /home/dh/kde/trunk/kate/part/syntax/katecodefolding.h:225 #10 0xb365625b in KateCodeFoldingNode::matchingNode (this=0x8ab0a30) at /home/dh/kde/trunk/kate/part/syntax/katecodefolding.h:228 #11 0xb364ff28 in KateCodeFoldingNode::getStartMatching (this=0x8ab0a30, endNode=0x8a71558) at /home/dh/kde/trunk/kate/part/syntax/katecodefolding.cpp:155 #12 0xb365293e in KateCodeFoldingTree::getLineInfo (this=0x8469fc0, info=0xbfcc32bc, line=504) at /home/dh/kde/trunk/kate/part/syntax/katecodefolding.cpp:996 #13 0xb35db8bb in KateBuffer::lineInfo (this=0x8469f38, info=0xbfcc32bc, line=504) at /home/dh/kde/trunk/kate/part/document/katebuffer.h:187 #14 0xb35d31b5 in KateDocument::lineInfo (this=0x8469918, info=0xbfcc32bc, line=504) at /home/dh/kde/trunk/kate/part/document/katedocument.cpp:4041 #15 0xb36875c0 in KateIconBorder::paintBorder (this=0x81d8f28, y=0, height=453) at /home/dh/kde/trunk/kate/part/view/kateviewhelpers.cpp:1194 #16 0xb3685f51 in KateIconBorder::paintEvent (this=0x81d8f28, e=0xbfcc3a04) at /home/dh/kde/trunk/kate/part/view/kateviewhelpers.cpp:952
==20258== Invalid read of size 4 ==20258== at 0xA9E9F11: KateCodeFoldingNode::getStartMatching(KateCodeFoldingNode*) (katecodefolding.cpp:151) ==20258== by 0xA9EC93D: KateCodeFoldingTree::getLineInfo(KateLineInfo*, int) const (katecodefolding.cpp:996) ==20258== by 0xA9758BA: KateBuffer::lineInfo(KateLineInfo*, int) const (katebuffer.h:187) ==20258== by 0xA96D1B4: KateDocument::lineInfo(KateLineInfo*, int) const (katedocument.cpp:4041) ==20258== by 0xAA215BF: KateIconBorder::paintBorder(int, int, int, int) (kateviewhelpers.cpp:1194) ==20258== by 0xAA1FF50: KateIconBorder::paintEvent(QPaintEvent*) (kateviewhelpers.cpp:952) ==20258== by 0x4C36EE9: QWidget::event(QEvent*) (in /usr/lib/libQtGui.so.4.8.0) ==20258== by 0x4BDB8D3: QApplicationPrivate::notify_helper(QObject*, QEvent*) (in /usr/lib/libQtGui.so.4.8.0) ==20258== by 0x4BE47DC: QApplication::notify(QObject*, QEvent*) (in /usr/lib/libQtGui.so.4.8.0) ==20258== Address 0x9c3d024 is 20 bytes inside a block of size 44 free'd ==20258== at 0x4027F13: operator delete(void*) (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so) ==20258== by 0xA9EB719: KateCodeFoldingTree::deleteStartNode(KateCodeFoldingNode*) (katecodefolding.cpp:640) ==20258== by 0xA9F0303: KateCodeFoldingTree::deleteNode(KateCodeFoldingNode*) (katecodefolding.h:353) ==20258== by 0xA9EEBAC: KateCodeFoldingTree::updateMapping(int, QVector<int> const&, int, int) (katecodefolding.cpp:1578) ==20258== by 0xA9EE7D6: KateCodeFoldingTree::updateLine(int, QVector<int> const&, bool*, bool, bool) (katecodefolding.cpp:1504) ==20258== by 0xA9817D3: KateBuffer::doHighlight(int, int, bool) (katebuffer.cpp:706) ==20258== by 0xA980693: KateBuffer::ensureHighlighted(int) (katebuffer.cpp:250) ==20258== by 0xA9719CF: KateDocument::kateTextLine(unsigned int) (katedocument.cpp:4786) ==20258== by 0xA9B7B75: KateLineLayout::textLine(bool) const (katelinelayout.cpp:67) ==20258== by 0xA9B3A5A: KateLayoutCache::line(int, int) (katelayoutcache.cpp:298) ==20258== by 0xA9B3825: KateLayoutCache::updateViewCache(KTextEditor::Cursor const&, int, int) (katelayoutcache.cpp:270) ==20258== by 0xAA1126F: KateViewInternal::tagLines(KTextEditor::Cursor, KTextEditor::Cursor, bool) (kateviewinternal.cpp:1979) ==20258== ==20258== Invalid read of size 4 ==20258== at 0xA9F03B0: QVector<KateCodeFoldingNode*>::isEmpty() const (qvector.h:139) ==20258== by 0xA9F0183: KateCodeFoldingNode::noEndChildren() const (katecodefolding.h:197) ==20258== by 0xA9F0236: KateCodeFoldingNode::hasMatch() const (in usr/lib/libkatepartinterfaces.so.4.8.0) ==20258== by 0xA9F025A: KateCodeFoldingNode::matchingNode() const (in usr/lib/libkatepartinterfaces.so.4.8.0) ==20258== by 0xA9E9F27: KateCodeFoldingNode::getStartMatching(KateCodeFoldingNode*) (katecodefolding.cpp:155) ==20258== by 0xA9EC93D: KateCodeFoldingTree::getLineInfo(KateLineInfo*, int) const (katecodefolding.cpp:996) ==20258== by 0xA9758BA: KateBuffer::lineInfo(KateLineInfo*, int) const (katebuffer.h:187) ==20258== by 0xA96D1B4: KateDocument::lineInfo(KateLineInfo*, int) const (katedocument.cpp:4041) ==20258== by 0xAA215BF: KateIconBorder::paintBorder(int, int, int, int) (kateviewhelpers.cpp:1194) ==20258== by 0xAA1FF50: KateIconBorder::paintEvent(QPaintEvent*) (kateviewhelpers.cpp:952) ==20258== by 0x4C36EE9: QWidget::event(QEvent*) (in /usr/lib/libQtGui.so.4.8.0) ==20258== by 0x4BDB8D3: QApplicationPrivate::notify_helper(QObject*, QEvent*) (in /usr/lib/libQtGui.so.4.8.0) ==20258== Address 0x9c3d034 is 36 bytes inside a block of size 44 free'd ==20258== at 0x4027F13: operator delete(void*) (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so) ==20258== by 0xA9EB719: KateCodeFoldingTree::deleteStartNode(KateCodeFoldingNode*) (katecodefolding.cpp:640) ==20258== by 0xA9F0303: KateCodeFoldingTree::deleteNode(KateCodeFoldingNode*) (katecodefolding.h:353) ==20258== by 0xA9EEBAC: KateCodeFoldingTree::updateMapping(int, QVector<int> const&, int, int) (katecodefolding.cpp:1578) ==20258== by 0xA9EE7D6: KateCodeFoldingTree::updateLine(int, QVector<int> const&, bool*, bool, bool) (katecodefolding.cpp:1504) ==20258== by 0xA9817D3: KateBuffer::doHighlight(int, int, bool) (katebuffer.cpp:706) ==20258== by 0xA980693: KateBuffer::ensureHighlighted(int) (katebuffer.cpp:250) ==20258== by 0xA9719CF: KateDocument::kateTextLine(unsigned int) (katedocument.cpp:4786) ==20258== by 0xA9B7B75: KateLineLayout::textLine(bool) const (katelinelayout.cpp:67) ==20258== by 0xA9B3A5A: KateLayoutCache::line(int, int) (katelayoutcache.cpp:298) ==20258== by 0xA9B3825: KateLayoutCache::updateViewCache(KTextEditor::Cursor const&, int, int) (katelayoutcache.cpp:270) ==20258== by 0xAA1126F: KateViewInternal::tagLines(KTextEditor::Cursor, KTextEditor::Cursor, bool) (kateviewinternal.cpp:1979) ==20258== ==20258== Invalid read of size 4 ==20258== at 0xA9F03B2: QVector<KateCodeFoldingNode*>::isEmpty() const (qvector.h:139) ==20258== by 0xA9F0183: KateCodeFoldingNode::noEndChildren() const (katecodefolding.h:197) ==20258== by 0xA9F0236: KateCodeFoldingNode::hasMatch() const (in usr/lib/libkatepartinterfaces.so.4.8.0) ==20258== by 0xA9F025A: KateCodeFoldingNode::matchingNode() const (in usr/lib/libkatepartinterfaces.so.4.8.0) ==20258== by 0xA9E9F27: KateCodeFoldingNode::getStartMatching(KateCodeFoldingNode*) (katecodefolding.cpp:155) ==20258== by 0xA9EC93D: KateCodeFoldingTree::getLineInfo(KateLineInfo*, int) const (katecodefolding.cpp:996) ==20258== by 0xA9758BA: KateBuffer::lineInfo(KateLineInfo*, int) const (katebuffer.h:187) ==20258== by 0xA96D1B4: KateDocument::lineInfo(KateLineInfo*, int) const (katedocument.cpp:4041) ==20258== by 0xAA215BF: KateIconBorder::paintBorder(int, int, int, int) (kateviewhelpers.cpp:1194) ==20258== by 0xAA1FF50: KateIconBorder::paintEvent(QPaintEvent*) (kateviewhelpers.cpp:952) ==20258== by 0x4C36EE9: QWidget::event(QEvent*) (in /usr/lib/libQtGui.so.4.8.0) ==20258== by 0x4BDB8D3: QApplicationPrivate::notify_helper(QObject*, QEvent*) (in /usr/lib/libQtGui.so.4.8.0) ==20258== Address 0x9c3d0f8 is 8 bytes inside a block of size 24 free'd ==20258== at 0x4028283: free (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so) ==20258== by 0xA9F167B: QVector<KateCodeFoldingNode*>::free(QVectorTypedData<KateCodeFoldingNode*>*) (qvector.h:468) ==20258== by 0xA9F04CC: QVector<KateCodeFoldingNode*>::~QVector() (in usr/lib/libkatepartinterfaces.so.4.8.0) ==20258== by 0xA9E9B32: KateCodeFoldingNode::~KateCodeFoldingNode() (katecodefolding.cpp:62) ==20258== by 0xA9E9B86: KateCodeFoldingNode::~KateCodeFoldingNode() (katecodefolding.cpp:66) ==20258== by 0xA9EB719: KateCodeFoldingTree::deleteStartNode(KateCodeFoldingNode*) (katecodefolding.cpp:640) ==20258== by 0xA9F0303: KateCodeFoldingTree::deleteNode(KateCodeFoldingNode*) (katecodefolding.h:353) ==20258== by 0xA9EEBAC: KateCodeFoldingTree::updateMapping(int, QVector<int> const&, int, int) (katecodefolding.cpp:1578) ==20258== by 0xA9EE7D6: KateCodeFoldingTree::updateLine(int, QVector<int> const&, bool*, bool, bool) (katecodefolding.cpp:1504) ==20258== by 0xA9817D3: KateBuffer::doHighlight(int, int, bool) (katebuffer.cpp:706) ==20258== by 0xA980693: KateBuffer::ensureHighlighted(int) (katebuffer.cpp:250) ==20258== by 0xA9719CF: KateDocument::kateTextLine(unsigned int) (katedocument.cpp:4786) ==20258== ==20258== Invalid read of size 4 ==20258== at 0xA9F03E5: QVector<KateCodeFoldingNode*>::operator[](int) const (qvector.h:355) ==20258== by 0xA9F01D6: KateCodeFoldingNode::endChildAt(unsigned int) const (katecodefolding.h:209) ==20258== by 0xA9F0271: KateCodeFoldingNode::matchingNode() const (in usr/lib/libkatepartinterfaces.so.4.8.0) ==20258== by 0xA9E9F27: KateCodeFoldingNode::getStartMatching(KateCodeFoldingNode*) (katecodefolding.cpp:155) ==20258== by 0xA9EC93D: KateCodeFoldingTree::getLineInfo(KateLineInfo*, int) const (katecodefolding.cpp:996) ==20258== by 0xA9758BA: KateBuffer::lineInfo(KateLineInfo*, int) const (katebuffer.h:187) ==20258== by 0xA96D1B4: KateDocument::lineInfo(KateLineInfo*, int) const (katedocument.cpp:4041) ==20258== by 0xAA215BF: KateIconBorder::paintBorder(int, int, int, int) (kateviewhelpers.cpp:1194) ==20258== by 0xAA1FF50: KateIconBorder::paintEvent(QPaintEvent*) (kateviewhelpers.cpp:952) ==20258== by 0x4C36EE9: QWidget::event(QEvent*) (in /usr/lib/libQtGui.so.4.8.0) ==20258== by 0x4BDB8D3: QApplicationPrivate::notify_helper(QObject*, QEvent*) (in /usr/lib/libQtGui.so.4.8.0) ==20258== by 0x4BE47DC: QApplication::notify(QObject*, QEvent*) (in /usr/lib/libQtGui.so.4.8.0) ==20258== Address 0x9c3d034 is 36 bytes inside a block of size 44 free'd ==20258== at 0x4027F13: operator delete(void*) (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so) ==20258== by 0xA9EB719: KateCodeFoldingTree::deleteStartNode(KateCodeFoldingNode*) (katecodefolding.cpp:640) ==20258== by 0xA9F0303: KateCodeFoldingTree::deleteNode(KateCodeFoldingNode*) (katecodefolding.h:353) ==20258== by 0xA9EEBAC: KateCodeFoldingTree::updateMapping(int, QVector<int> const&, int, int) (katecodefolding.cpp:1578) ==20258== by 0xA9EE7D6: KateCodeFoldingTree::updateLine(int, QVector<int> const&, bool*, bool, bool) (katecodefolding.cpp:1504) ==20258== by 0xA9817D3: KateBuffer::doHighlight(int, int, bool) (katebuffer.cpp:706) ==20258== by 0xA980693: KateBuffer::ensureHighlighted(int) (katebuffer.cpp:250) ==20258== by 0xA9719CF: KateDocument::kateTextLine(unsigned int) (katedocument.cpp:4786) ==20258== by 0xA9B7B75: KateLineLayout::textLine(bool) const (katelinelayout.cpp:67) ==20258== by 0xA9B3A5A: KateLayoutCache::line(int, int) (katelayoutcache.cpp:298) ==20258== by 0xA9B3825: KateLayoutCache::updateViewCache(KTextEditor::Cursor const&, int, int) (katelayoutcache.cpp:270) ==20258== by 0xAA1126F: KateViewInternal::tagLines(KTextEditor::Cursor, KTextEditor::Cursor, bool) (kateviewinternal.cpp:1979) ==20258== ==20258== Invalid read of size 4 ==20258== at 0xA9F03E7: QVector<KateCodeFoldingNode*>::operator[](int) const (qvector.h:355) ==20258== by 0xA9F01D6: KateCodeFoldingNode::endChildAt(unsigned int) const (katecodefolding.h:209) ==20258== by 0xA9F0271: KateCodeFoldingNode::matchingNode() const (in usr/lib/libkatepartinterfaces.so.4.8.0) ==20258== by 0xA9E9F27: KateCodeFoldingNode::getStartMatching(KateCodeFoldingNode*) (katecodefolding.cpp:155) ==20258== by 0xA9EC93D: KateCodeFoldingTree::getLineInfo(KateLineInfo*, int) const (katecodefolding.cpp:996) ==20258== by 0xA9758BA: KateBuffer::lineInfo(KateLineInfo*, int) const (katebuffer.h:187) ==20258== by 0xA96D1B4: KateDocument::lineInfo(KateLineInfo*, int) const (katedocument.cpp:4041) ==20258== by 0xAA215BF: KateIconBorder::paintBorder(int, int, int, int) (kateviewhelpers.cpp:1194) ==20258== by 0xAA1FF50: KateIconBorder::paintEvent(QPaintEvent*) (kateviewhelpers.cpp:952) ==20258== by 0x4C36EE9: QWidget::event(QEvent*) (in /usr/lib/libQtGui.so.4.8.0) ==20258== by 0x4BDB8D3: QApplicationPrivate::notify_helper(QObject*, QEvent*) (in /usr/lib/libQtGui.so.4.8.0) ==20258== by 0x4BE47DC: QApplication::notify(QObject*, QEvent*) (in /usr/lib/libQtGui.so.4.8.0) ==20258== Address 0x9c3d0f8 is 8 bytes inside a block of size 24 free'd ==20258== at 0x4028283: free (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so) ==20258== by 0xA9F167B: QVector<KateCodeFoldingNode*>::free(QVectorTypedData<KateCodeFoldingNode*>*) (qvector.h:468) ==20258== by 0xA9F04CC: QVector<KateCodeFoldingNode*>::~QVector() (in usr/lib/libkatepartinterfaces.so.4.8.0) ==20258== by 0xA9E9B32: KateCodeFoldingNode::~KateCodeFoldingNode() (katecodefolding.cpp:62) ==20258== by 0xA9E9B86: KateCodeFoldingNode::~KateCodeFoldingNode() (katecodefolding.cpp:66) ==20258== by 0xA9EB719: KateCodeFoldingTree::deleteStartNode(KateCodeFoldingNode*) (katecodefolding.cpp:640) ==20258== by 0xA9F0303: KateCodeFoldingTree::deleteNode(KateCodeFoldingNode*) (katecodefolding.h:353) ==20258== by 0xA9EEBAC: KateCodeFoldingTree::updateMapping(int, QVector<int> const&, int, int) (katecodefolding.cpp:1578) ==20258== by 0xA9EE7D6: KateCodeFoldingTree::updateLine(int, QVector<int> const&, bool*, bool, bool) (katecodefolding.cpp:1504) ==20258== by 0xA9817D3: KateBuffer::doHighlight(int, int, bool) (katebuffer.cpp:706) ==20258== by 0xA980693: KateBuffer::ensureHighlighted(int) (katebuffer.cpp:250) ==20258== by 0xA9719CF: KateDocument::kateTextLine(unsigned int) (katedocument.cpp:4786) ==20258== ==20258== Invalid read of size 4 ==20258== at 0xA9F0423: QVector<KateCodeFoldingNode*>::operator[](int) const (qvector.h:356) ==20258== by 0xA9F01D6: KateCodeFoldingNode::endChildAt(unsigned int) const (katecodefolding.h:209) ==20258== by 0xA9F0271: KateCodeFoldingNode::matchingNode() const (in usr/lib/libkatepartinterfaces.so.4.8.0) ==20258== by 0xA9E9F27: KateCodeFoldingNode::getStartMatching(KateCodeFoldingNode*) (katecodefolding.cpp:155) ==20258== by 0xA9EC93D: KateCodeFoldingTree::getLineInfo(KateLineInfo*, int) const (katecodefolding.cpp:996) ==20258== by 0xA9758BA: KateBuffer::lineInfo(KateLineInfo*, int) const (katebuffer.h:187) ==20258== by 0xA96D1B4: KateDocument::lineInfo(KateLineInfo*, int) const (katedocument.cpp:4041) ==20258== by 0xAA215BF: KateIconBorder::paintBorder(int, int, int, int) (kateviewhelpers.cpp:1194) ==20258== by 0xAA1FF50: KateIconBorder::paintEvent(QPaintEvent*) (kateviewhelpers.cpp:952) ==20258== by 0x4C36EE9: QWidget::event(QEvent*) (in /usr/lib/libQtGui.so.4.8.0) ==20258== by 0x4BDB8D3: QApplicationPrivate::notify_helper(QObject*, QEvent*) (in /usr/lib/libQtGui.so.4.8.0) ==20258== by 0x4BE47DC: QApplication::notify(QObject*, QEvent*) (in /usr/lib/libQtGui.so.4.8.0) ==20258== Address 0x9c3d034 is 36 bytes inside a block of size 44 free'd ==20258== at 0x4027F13: operator delete(void*) (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so) ==20258== by 0xA9EB719: KateCodeFoldingTree::deleteStartNode(KateCodeFoldingNode*) (katecodefolding.cpp:640) ==20258== by 0xA9F0303: KateCodeFoldingTree::deleteNode(KateCodeFoldingNode*) (katecodefolding.h:353) ==20258== by 0xA9EEBAC: KateCodeFoldingTree::updateMapping(int, QVector<int> const&, int, int) (katecodefolding.cpp:1578) ==20258== by 0xA9EE7D6: KateCodeFoldingTree::updateLine(int, QVector<int> const&, bool*, bool, bool) (katecodefolding.cpp:1504) ==20258== by 0xA9817D3: KateBuffer::doHighlight(int, int, bool) (katebuffer.cpp:706) ==20258== by 0xA980693: KateBuffer::ensureHighlighted(int) (katebuffer.cpp:250) ==20258== by 0xA9719CF: KateDocument::kateTextLine(unsigned int) (katedocument.cpp:4786) ==20258== by 0xA9B7B75: KateLineLayout::textLine(bool) const (katelinelayout.cpp:67) ==20258== by 0xA9B3A5A: KateLayoutCache::line(int, int) (katelayoutcache.cpp:298) ==20258== by 0xA9B3825: KateLayoutCache::updateViewCache(KTextEditor::Cursor const&, int, int) (katelayoutcache.cpp:270) ==20258== by 0xAA1126F: KateViewInternal::tagLines(KTextEditor::Cursor, KTextEditor::Cursor, bool) (kateviewinternal.cpp:1979) ==20258== ==20258== Invalid read of size 4 ==20258== at 0xA9F01D7: KateCodeFoldingNode::endChildAt(unsigned int) const (katecodefolding.h:209) ==20258== by 0xA9F0271: KateCodeFoldingNode::matchingNode() const (in usr/lib/libkatepartinterfaces.so.4.8.0) ==20258== by 0xA9E9F27: KateCodeFoldingNode::getStartMatching(KateCodeFoldingNode*) (katecodefolding.cpp:155) ==20258== by 0xA9EC93D: KateCodeFoldingTree::getLineInfo(KateLineInfo*, int) const (katecodefolding.cpp:996) ==20258== by 0xA9758BA: KateBuffer::lineInfo(KateLineInfo*, int) const (katebuffer.h:187) ==20258== by 0xA96D1B4: KateDocument::lineInfo(KateLineInfo*, int) const (katedocument.cpp:4041) ==20258== by 0xAA215BF: KateIconBorder::paintBorder(int, int, int, int) (kateviewhelpers.cpp:1194) ==20258== by 0xAA1FF50: KateIconBorder::paintEvent(QPaintEvent*) (kateviewhelpers.cpp:952) ==20258== by 0x4C36EE9: QWidget::event(QEvent*) (in /usr/lib/libQtGui.so.4.8.0) ==20258== by 0x4BDB8D3: QApplicationPrivate::notify_helper(QObject*, QEvent*) (in /usr/lib/libQtGui.so.4.8.0) ==20258== by 0x4BE47DC: QApplication::notify(QObject*, QEvent*) (in /usr/lib/libQtGui.so.4.8.0) ==20258== Address 0x9c3d100 is 16 bytes inside a block of size 24 free'd ==20258== at 0x4028283: free (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so) ==20258== by 0xA9F167B: QVector<KateCodeFoldingNode*>::free(QVectorTypedData<KateCodeFoldingNode*>*) (qvector.h:468) ==20258== by 0xA9F04CC: QVector<KateCodeFoldingNode*>::~QVector() (in usr/lib/libkatepartinterfaces.so.4.8.0) ==20258== by 0xA9E9B32: KateCodeFoldingNode::~KateCodeFoldingNode() (katecodefolding.cpp:62) ==20258== by 0xA9E9B86: KateCodeFoldingNode::~KateCodeFoldingNode() (katecodefolding.cpp:66) ==20258== by 0xA9EB719: KateCodeFoldingTree::deleteStartNode(KateCodeFoldingNode*) (katecodefolding.cpp:640) ==20258== by 0xA9F0303: KateCodeFoldingTree::deleteNode(KateCodeFoldingNode*) (katecodefolding.h:353) ==20258== by 0xA9EEBAC: KateCodeFoldingTree::updateMapping(int, QVector<int> const&, int, int) (katecodefolding.cpp:1578) ==20258== by 0xA9EE7D6: KateCodeFoldingTree::updateLine(int, QVector<int> const&, bool*, bool, bool) (katecodefolding.cpp:1504) ==20258== by 0xA9817D3: KateBuffer::doHighlight(int, int, bool) (katebuffer.cpp:706) ==20258== by 0xA980693: KateBuffer::ensureHighlighted(int) (katebuffer.cpp:250) ==20258== by 0xA9719CF: KateDocument::kateTextLine(unsigned int) (katedocument.cpp:4786) ==20258== ==20258== Invalid read of size 4 ==20258== at 0xA9E9F3A: KateCodeFoldingNode::getStartMatching(KateCodeFoldingNode*) (katecodefolding.cpp:159) ==20258== by 0xA9EC93D: KateCodeFoldingTree::getLineInfo(KateLineInfo*, int) const (katecodefolding.cpp:996) ==20258== by 0xA9758BA: KateBuffer::lineInfo(KateLineInfo*, int) const (katebuffer.h:187) ==20258== by 0xA96D1B4: KateDocument::lineInfo(KateLineInfo*, int) const (katedocument.cpp:4041) ==20258== by 0xAA215BF: KateIconBorder::paintBorder(int, int, int, int) (kateviewhelpers.cpp:1194) ==20258== by 0xAA1FF50: KateIconBorder::paintEvent(QPaintEvent*) (kateviewhelpers.cpp:952) ==20258== by 0x4C36EE9: QWidget::event(QEvent*) (in /usr/lib/libQtGui.so.4.8.0) ==20258== by 0x4BDB8D3: QApplicationPrivate::notify_helper(QObject*, QEvent*) (in /usr/lib/libQtGui.so.4.8.0) ==20258== by 0x4BE47DC: QApplication::notify(QObject*, QEvent*) (in /usr/lib/libQtGui.so.4.8.0) ==20258== Address 0x9c3d018 is 8 bytes inside a block of size 44 free'd ==20258== at 0x4027F13: operator delete(void*) (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so) ==20258== by 0xA9EB719: KateCodeFoldingTree::deleteStartNode(KateCodeFoldingNode*) (katecodefolding.cpp:640) ==20258== by 0xA9F0303: KateCodeFoldingTree::deleteNode(KateCodeFoldingNode*) (katecodefolding.h:353) ==20258== by 0xA9EEBAC: KateCodeFoldingTree::updateMapping(int, QVector<int> const&, int, int) (katecodefolding.cpp:1578) ==20258== by 0xA9EE7D6: KateCodeFoldingTree::updateLine(int, QVector<int> const&, bool*, bool, bool) (katecodefolding.cpp:1504) ==20258== by 0xA9817D3: KateBuffer::doHighlight(int, int, bool) (katebuffer.cpp:706) ==20258== by 0xA980693: KateBuffer::ensureHighlighted(int) (katebuffer.cpp:250) ==20258== by 0xA9719CF: KateDocument::kateTextLine(unsigned int) (katedocument.cpp:4786) ==20258== by 0xA9B7B75: KateLineLayout::textLine(bool) const (katelinelayout.cpp:67) ==20258== by 0xA9B3A5A: KateLayoutCache::line(int, int) (katelayoutcache.cpp:298) ==20258== by 0xA9B3825: KateLayoutCache::updateViewCache(KTextEditor::Cursor const&, int, int) (katelayoutcache.cpp:270) ==20258== by 0xAA1126F: KateViewInternal::tagLines(KTextEditor::Cursor, KTextEditor::Cursor, bool) (kateviewinternal.cpp:1979) ==20258==
add crash unit test case for bug 294241 http://quickgit.kde.org/?p=kate.git&a=commit&h=bf2002eff03d1b670b504a3c02db3bdb1495ee9f
I will handle it in a couple of days. I will write the test case as well. Thanks for the notice.
The test case already exists, see comment #4. Right now, it crashes. I had a look but didn't immediately find the bug.
FWIW the unclosed XML tag is part of the problem because it stopped crashing once I fixed that in vim. Thanks Dominik for getting a full backtrace for me! :-)
*** Bug 293934 has been marked as a duplicate of this bug. ***
http://commits.kde.org/kate/4dee862b88aeab22600bce40517723ce78b8ba12 There are now two unit test cases that crash code folding (probably the same issue). Just execute in build/part/tests the unit test ./bug294241_test.shell and it will crash.
Created attachment 69092 [details] New crash information added by DrKonqi kate (3.8.0) on KDE Platform 4.8.00 (4.8.0 using Qt 4.8.0 I hit this again with yet another docbook in progress. :-( I'm not sure if another example file is helpful, but I might as well give it to you anyway. ;-) -- Backtrace (Reduced): #6 0x00007f18a6402c78 in KateCodeFoldingTree::getLineInfo(KateLineInfo*, int) const () from /usr/lib64/libkatepartinterfaces.so.4 [...] #8 0x0000003dcf819fdc in QWidget::event(QEvent*) () from /usr/lib64/libQtGui.so.4 #9 0x0000003dcf7c9994 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /usr/lib64/libQtGui.so.4 #10 0x0000003dcf7ce813 in QApplication::notify(QObject*, QEvent*) () from /usr/lib64/libQtGui.so.4 #11 0x0000003dcf050eb6 in KApplication::notify(QObject*, QEvent*) () from /usr/lib64/libkdeui.so.5
Created attachment 69093 [details] yet another crashy docbook Just open this and Kate will crash within seconds.
*** Bug 292921 has been marked as a duplicate of this bug. ***
Bug fixed
*** Bug 296177 has been marked as a duplicate of this bug. ***
Confirmed fixed in current master. Thanks Adrian!
*** Bug 296428 has been marked as a duplicate of this bug. ***
*** Bug 297261 has been marked as a duplicate of this bug. ***
*** Bug 297317 has been marked as a duplicate of this bug. ***
The bug still exists (or reappeared), since its unit test fails. Any takers?
Created attachment 78249 [details] New crash information added by DrKonqi kate (3.8.4) on KDE Platform 4.8.4 (4.8.4) using Qt 4.8.2 - What I was doing when the application crashed: I was editing python code, the crash happened when just typing a closing brace (or immediately before that, not 100% sure). -- Backtrace (Reduced): #7 0xf2074d7e in QVector<KateCodeFoldingNode*>::isEmpty (this=0xa8f0114) at /usr/include/qt4/QtCore/qvector.h:139 #8 0xf2074b50 in KateCodeFoldingNode::noEndChildren (this=0xa8f00f0) at /home/andreas/src/kate/part/syntax/katecodefolding.h:147 #9 0xf2074c03 in KateCodeFoldingNode::hasMatch (this=0xa8f00f0) at /home/andreas/src/kate/part/syntax/katecodefolding.h:175 #10 0xf2074c27 in KateCodeFoldingNode::matchingNode (this=0xa8f00f0) at /home/andreas/src/kate/part/syntax/katecodefolding.h:178 #11 0xf206e8c4 in KateCodeFoldingNode::getStartMatching (this=0xa8f00f0, endNode=0xa9063c0) at /home/andreas/src/kate/part/syntax/katecodefolding.cpp:144
*** Bug 306369 has been marked as a duplicate of this bug. ***
*** Bug 308139 has been marked as a duplicate of this bug. ***
*** Bug 311180 has been marked as a duplicate of this bug. ***
*** Bug 309846 has been marked as a duplicate of this bug. ***
*** Bug 317207 has been marked as a duplicate of this bug. ***
*** Bug 309784 has been marked as a duplicate of this bug. ***
Fixed in master by a complete rewrite of all folding related stuff, zero code in common with old implementation!
*** Bug 324017 has been marked as a duplicate of this bug. ***
*** Bug 325804 has been marked as a duplicate of this bug. ***