Summary: | Empty highlighting definition produces segfault | ||
---|---|---|---|
Product: | [Applications] kate | Reporter: | hansoa2 |
Component: | general | Assignee: | KWrite Developers <kwrite-bugs-null> |
Status: | RESOLVED FIXED | ||
Severity: | crash | CC: | aretae |
Priority: | VHI | Keywords: | drkonqi |
Version First Reported In: | 3.10.5 | ||
Target Milestone: | --- | ||
Platform: | Fedora RPMs | ||
OS: | Linux | ||
Latest Commit: | http://commits.kde.org/kate/dd9463ab061a955ce777513393002c664fed6641 | Version Fixed In: | 4.12 |
Sentry Crash Report: |
Description
hansoa2
2013-08-08 02:54:54 UTC
*** Bug 267977 has been marked as a duplicate of this bug. *** Confirmed, F7, set-highlight emptyxmlfile -> crash: Thread 1 (Thread 0x7faff2762780 (LWP 11067)): [KCrash Handler] #5 0x00007faff9273d25 in raise () from /lib64/libc.so.6 #6 0x00007faff92751a8 in abort () from /lib64/libc.so.6 #7 0x00007faffa5d6c14 in qt_message_output (msgType=msgType@entry=QtFatalMsg, buf=<optimized out>) at global/qglobal.cpp:2323 #8 0x00007faffa5d6dc8 in qt_message(QtMsgType, const char *, typedef __va_list_tag __va_list_tag *) (msgType=msgType@entry=QtFatalMsg, msg=msg@entry=0x7faffa73fac8 "ASSERT: \"%s\" in file %s, line %d", ap=ap@entry=0x7fff1f200778) at global/qglobal.cpp:2369 #9 0x00007faffa5d6f54 in qFatal (msg=msg@entry=0x7faffa73fac8 "ASSERT: \"%s\" in file %s, line %d") at global/qglobal.cpp:2552 #10 0x00007faffa5d6f9a in qt_assert (assertion=<optimized out>, file=<optimized out>, line=<optimized out>) at global/qglobal.cpp:2018 #11 0x00007fafec7d1420 in KateHighlighting::contextNum (this=0xb2f030, n=0) at /home/dhaumann/local/projects/kate/part/syntax/katehighlight.h:267 #12 0x00007fafec834628 in KateHighlighting::doHighlight (this=0xb2f030, _prevLine=0x0, textLine=0xc1ffb0, nextLine=0xba2b40, ctxChanged=@0x7fff1f200a8b: false, tabWidth=8) at /home/dhaumann/local/projects/kate/part/syntax/katehighlight.cpp:286 #13 0x00007fafec7ddbf1 in KateBuffer::doHighlight (this=0xb4b830, startLine=0, endLine=0, invalidate=false) at /home/dhaumann/local/projects/kate/part/document/katebuffer.cpp:464 #14 0x00007fafec7dd4b1 in KateBuffer::ensureHighlighted (this=0xb4b830, line=0, lookAhead=64) at /home/dhaumann/local/projects/kate/part/document/katebuffer.cpp:298 #15 0x00007fafec7ccb44 in KateDocument::kateTextLine (this=0xb4afb0, i=0) at /home/dhaumann/local/projects/kate/part/document/katedocument.cpp:4702 #16 0x00007fafec819ba0 in KateLineLayout::textLine (this=0xa1c9a0, reloadForce=false) at /home/dhaumann/local/projects/kate/part/render/katelinelayout.cpp:68 #17 0x00007fafec80f942 in KateRenderer::layoutLine (this=0x140b070, lineLayout=..., maxwidth=-1, cacheLayout=true) at /home/dhaumann/local/projects/kate/part/render/katerenderer.cpp:916 #18 0x00007fafec8158c6 in KateLayoutCache::line (this=0x141a420, realLine=0, virtualLine=-1) at /home/dhaumann/local/projects/kate/part/render/katelayoutcache.cpp:322 #19 0x00007fafec815009 in KateLayoutCache::updateViewCache (this=0x141a420, startPos=..., newViewLineCount=39, viewLinesScrolled=0) at /home/dhaumann/local/projects/kate/part/render/katelayoutcache.cpp:233 #20 0x00007fafec868998 in KateViewInternal::doUpdateView (this=0x1419c00, changed=true, viewLinesScrolled=0) at /home/dhaumann/local/projects/kate/part/view/kateviewinternal.cpp:549 #21 0x00007fafec868809 in KateViewInternal::updateView (this=0x1419c00, changed=true, viewLinesScrolled=0) at /home/dhaumann/local/projects/kate/part/view/kateviewinternal.cpp:523 #22 0x00007fafec85eb47 in KateView::updateView (this=0x140a690, changed=true) at /home/dhaumann/local/projects/kate/part/view/kateview.cpp:1879 #23 0x00007fafec7bfaff in KateDocument::makeAttribs (this=0xb4afb0, needInvalidate=false) at /home/dhaumann/local/projects/kate/part/document/katedocument.cpp:2513 #24 0x00007fafec7ba8e9 in KateDocument::bufferHlChanged (this=0xb4afb0) at /home/dhaumann/local/projects/kate/part/document/katedocument.cpp:1522 #25 0x00007fafec7dd7d2 in KateBuffer::setHighlight (this=0xb4b830, hlMode=186) at /home/dhaumann/local/projects/kate/part/document/katebuffer.cpp:381 #26 0x00007fafec7ba782 in KateDocument::setHighlightingMode (this=0xb4afb0, name=...) at /home/dhaumann/local/projects/kate/part/document/katedocument.cpp:1490 Possible fix: https://git.reviewboard.kde.org/r/111941/ Git commit dd9463ab061a955ce777513393002c664fed6641 by Dominik Haumann. Committed on 08/08/2013 at 13:00. Pushed by dhaumann into branch 'master'. fix crash when no "context" element exists In fact, the xml highlighting file is broken in this case. Avoiding a crash in this case is good, though. FIXED-IN: 4.12 REVIEW: 111941 M +6 -0 part/syntax/katehighlight.cpp http://commits.kde.org/kate/dd9463ab061a955ce777513393002c664fed6641 |