Bug 311866 - [unit test] kate crashes if cursor is inside folded code block and up key is pressed
Summary: [unit test] kate crashes if cursor is inside folded code block and up key is ...
Status: RESOLVED FIXED
Alias: None
Product: kate
Classification: Applications
Component: folding (show other bugs)
Version: unspecified
Platform: Compiled Sources Linux
: NOR crash
Target Milestone: ---
Assignee: KWrite Developers
URL:
Keywords: testcase
: 313628 314245 317235 324146 324468 325133 (view as bug list)
Depends on:
Blocks:
 
Reported: 2012-12-18 08:02 UTC by uran238
Modified: 2015-02-27 03:26 UTC (History)
10 users (show)

See Also:
Latest Commit:
Version Fixed In: 4.11


Attachments
simpe source exposing the bug (77 bytes, text/plain)
2013-01-01 16:11 UTC, uran238
Details
New crash information added by DrKonqi (7.15 KB, text/plain)
2013-02-20 23:42 UTC, Andy
Details
possible fix (914 bytes, patch)
2013-04-16 13:17 UTC, Dominik Haumann
Details
correct patch this time (2.75 KB, patch)
2013-04-16 13:19 UTC, Dominik Haumann
Details

Note You need to log in before you can comment on or make changes to this bug.
Description uran238 2012-12-18 08:02:54 UTC
Application: kate (3.9.4)
KDE Platform Version: 4.9.4 (Compiled from sources)
Qt Version: 4.8.4
Operating System: Linux 3.7.0gcc47 x86_64
Distribution (Platform): Gentoo Packages

-- Information about the crash:
- What I was doing when the application crashed:

open some c sourcecode; position cursor in a code block; fold all blocks and press up key.
Will work with most sources, is always reproduceable, so try a different source if it won't crash.

The crash can be reproduced every time.

-- Backtrace:
Application: Kate (kdeinit4), signal: Segmentation fault
Using host libthread_db library "/lib64/libthread_db.so.1".
[Current thread is 1 (Thread 0x7ffc14cba780 (LWP 3497))]

Thread 2 (Thread 0x7ffbf879a700 (LWP 3556)):
#0  pthread_cond_wait () at ../nptl/sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S:164
#1  0x00007ffc027ca0e4 in ?? () from /usr/lib64/qt4/libQtScript.so.4
#2  0x00007ffc027ca119 in ?? () from /usr/lib64/qt4/libQtScript.so.4
#3  0x00007ffc1356ad36 in start_thread (arg=0x7ffbf879a700) at pthread_create.c:308
#4  0x00007ffc122ed9fd in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:114

Thread 1 (Thread 0x7ffc14cba780 (LWP 3497)):
[KCrash Handler]
#6  KateLineLayout::viewLineCount (this=0x0) at /var/tmp/portage/kde-base/katepart-4.9.4/work/katepart-4.9.4/part/render/katelinelayout.cpp:173
#7  0x00007ffbf93f18b8 in KateLineLayout::viewLine (this=<optimized out>, viewLine=<optimized out>) at /var/tmp/portage/kde-base/katepart-4.9.4/work/katepart-4.9.4/part/render/katelinelayout.cpp:179
#8  0x00007ffbf93ee536 in KateLayoutCache::textLayout (this=<optimized out>, realLine=<optimized out>, _viewLine=-1) at /var/tmp/portage/kde-base/katepart-4.9.4/work/katepart-4.9.4/part/render/katelayoutcache.cpp:351
#9  0x00007ffbf943690a in KateViewInternal::previousLayout (this=this@entry=0x19d4520) at /var/tmp/portage/kde-base/katepart-4.9.4/work/katepart-4.9.4/part/view/kateviewinternal.cpp:1257
#10 0x00007ffbf9440a53 in KateViewInternal::cursorUp (this=0x19d4520, sel=false) at /var/tmp/portage/kde-base/katepart-4.9.4/work/katepart-4.9.4/part/view/kateviewinternal.cpp:1425
#11 0x00007ffc13917da2 in QMetaObject::activate(QObject*, QMetaObject const*, int, void**) () from /usr/lib64/qt4/libQtCore.so.4
#12 0x00007ffc12a85aa2 in QAction::triggered(bool) () from /usr/lib64/qt4/libQtGui.so.4
#13 0x00007ffc12a85c9a in QAction::activate(QAction::ActionEvent) () from /usr/lib64/qt4/libQtGui.so.4
#14 0x00007ffc12a85dff in QAction::event(QEvent*) () from /usr/lib64/qt4/libQtGui.so.4
#15 0x00007ffc145e7207 in KAction::event (this=<optimized out>, event=0x7ffff454a990) at /var/tmp/portage/kde-base/kdelibs-4.9.4-r1/work/kdelibs-4.9.4/kdeui/actions/kaction.cpp:131
#16 0x00007ffc12a8bfa4 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /usr/lib64/qt4/libQtGui.so.4
#17 0x00007ffc12a909ef in QApplication::notify(QObject*, QEvent*) () from /usr/lib64/qt4/libQtGui.so.4
#18 0x00007ffc146bd906 in KApplication::notify (this=0x7ffff454c2c0, receiver=0x1b04b70, event=0x7ffff454a990) at /var/tmp/portage/kde-base/kdelibs-4.9.4-r1/work/kdelibs-4.9.4/kdeui/kernel/kapplication.cpp:311
#19 0x00007ffc139014e3 in QCoreApplication::notifyInternal(QObject*, QEvent*) () from /usr/lib64/qt4/libQtCore.so.4
#20 0x00007ffc12abdc83 in ?? () from /usr/lib64/qt4/libQtGui.so.4
#21 0x00007ffc12abf260 in ?? () from /usr/lib64/qt4/libQtGui.so.4
#22 0x00007ffc12a9252d in QApplication::notify(QObject*, QEvent*) () from /usr/lib64/qt4/libQtGui.so.4
#23 0x00007ffc146bd906 in KApplication::notify (this=0x7ffff454c2c0, receiver=0x19d4520, event=0x7ffff454af80) at /var/tmp/portage/kde-base/kdelibs-4.9.4-r1/work/kdelibs-4.9.4/kdeui/kernel/kapplication.cpp:311
#24 0x00007ffc139014e3 in QCoreApplication::notifyInternal(QObject*, QEvent*) () from /usr/lib64/qt4/libQtCore.so.4
#25 0x00007ffc12b2b897 in ?? () from /usr/lib64/qt4/libQtGui.so.4
#26 0x00007ffc12b2bcee in ?? () from /usr/lib64/qt4/libQtGui.so.4
#27 0x00007ffc12b084ba in QApplication::x11ProcessEvent(_XEvent*) () from /usr/lib64/qt4/libQtGui.so.4
#28 0x00007ffc12b2fd0a in ?? () from /usr/lib64/qt4/libQtGui.so.4
#29 0x00007ffc0f41ebaa in g_main_context_dispatch () from /usr/lib64/libglib-2.0.so.0
#30 0x00007ffc0f41eee8 in ?? () from /usr/lib64/libglib-2.0.so.0
#31 0x00007ffc0f41ef94 in g_main_context_iteration () from /usr/lib64/libglib-2.0.so.0
#32 0x00007ffc1392feef in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib64/qt4/libQtCore.so.4
#33 0x00007ffc12b2f9be in ?? () from /usr/lib64/qt4/libQtGui.so.4
#34 0x00007ffc13900292 in QEventLoop::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib64/qt4/libQtCore.so.4
#35 0x00007ffc13900545 in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib64/qt4/libQtCore.so.4
#36 0x00007ffc13904ea3 in QCoreApplication::exec() () from /usr/lib64/qt4/libQtCore.so.4
#37 0x00007ffbfd8b9a45 in kdemain (argc=<optimized out>, argv=0xa70000) at /var/tmp/portage/kde-base/kate-4.9.4/work/kate-4.9.4/kate/app/katemain.cpp:377
#38 0x0000000000408916 in launch (argc=argc@entry=3, _name=_name@entry=0xa716a8 "/usr/bin/kate", args=0xa716f7 "", args@entry=0xa716b6 "-session", cwd=cwd@entry=0x0, envc=envc@entry=0, envs=<optimized out>, envs@entry=0xa716ff "", reset_env=false, tty=tty@entry=0x0, avoid_loops=false, startup_id_str=startup_id_str@entry=0x40b0e6 "0") at /var/tmp/portage/kde-base/kdelibs-4.9.4-r1/work/kdelibs-4.9.4/kinit/kinit.cpp:726
#39 0x000000000040975b in handle_launcher_request (sock=7, who=<optimized out>) at /var/tmp/portage/kde-base/kdelibs-4.9.4-r1/work/kdelibs-4.9.4/kinit/kinit.cpp:1218
#40 0x0000000000409d93 in handle_requests (waitForPid=waitForPid@entry=0) at /var/tmp/portage/kde-base/kdelibs-4.9.4-r1/work/kdelibs-4.9.4/kinit/kinit.cpp:1411
#41 0x0000000000405b67 in main (argc=2, argv=<optimized out>, envp=0x7ffff454ce90) at /var/tmp/portage/kde-base/kdelibs-4.9.4-r1/work/kdelibs-4.9.4/kinit/kinit.cpp:1899

Possible duplicates by query: bug 302298, bug 260996.

Reported using DrKonqi
Comment 1 uran238 2013-01-01 16:11:01 UTC
Created attachment 76126 [details]
simpe source exposing the bug

place cursor at line 4, fold (with hotkey!), press up, crash
Comment 2 Dominik Haumann 2013-01-06 12:23:34 UTC
Git commit 2086aa205ab3d9450aa2a509894e5b9239cceb50 by Dominik Haumann.
Committed on 06/01/2013 at 13:22.
Pushed by dhaumann into branch 'master'.

add unit test for crash in code folding (bug311866)

todo: make sure the cursor position is valid (in visible text area)
if the code folding changes. This fix should not be done in
KateViewInternal::regionVisibilityChanged() as then we run into selection
bugs like e.g. http://bugs.kde.org/show_bug.cgi?id=295632

bug tracker: http://bugs.kde.org/show_bug.cgi?id=311866

A  +5    -0    part/tests/bug311866.cpp     [License: UNKNOWN]  *
M  +38   -0    part/tests/katefolding_test.cpp
M  +5    -4    part/tests/katefolding_test.h

The files marked with a * at the end have a non valid license. Please read: http://techbase.kde.org/Policies/Licensing_Policy and use the headers which are listed at that page.


http://commits.kde.org/kate/2086aa205ab3d9450aa2a509894e5b9239cceb50
Comment 3 Dominik Haumann 2013-02-20 10:57:40 UTC
*** Bug 313628 has been marked as a duplicate of this bug. ***
Comment 4 Dominik Haumann 2013-02-20 10:57:49 UTC
*** Bug 314245 has been marked as a duplicate of this bug. ***
Comment 5 Andy 2013-02-20 23:42:41 UTC
Created attachment 77479 [details]
New crash information added by DrKonqi

kwrite (4.9.4) on KDE Platform 4.9.4 using Qt 4.8.3

- What I was doing when the application crashed:

just folded code blocks, and then started scrolling up or down (I don't remember).

-- Backtrace (Reduced):
#6  KateLineLayout::viewLineCount (this=0x0) at ../../part/render/katelinelayout.cpp:173
#7  0x00007fa1904b8cfb in KateLayoutCache::lastViewLine (this=0x0, this@entry=0x24a0d40, realLine=38407488) at ../../part/render/katelayoutcache.cpp:461
#8  0x00007fa1904b8d49 in KateLayoutCache::viewLineCount (this=this@entry=0x24a0d40, realLine=<optimized out>) at ../../part/render/katelayoutcache.cpp:466
#9  0x00007fa1904b93e4 in KateLayoutCache::displayViewLine (this=0x24a0d40, virtualCursor=..., limitToVisible=<optimized out>) at ../../part/render/katelayoutcache.cpp:429
#10 0x00007fa19050af0a in KateViewInternal::pageDown (this=0x2498450, sel=<optimized out>, half=<optimized out>) at ../../part/view/kateviewinternal.cpp:1572
Comment 6 Dominik Haumann 2013-03-23 15:41:36 UTC
@Christoph: Still reproducible. To be checked with new code folding, so best adapt the test to at least test once before deleting the test.
Comment 7 Dominik Haumann 2013-03-23 15:43:08 UTC
*** Bug 317235 has been marked as a duplicate of this bug. ***
Comment 8 Christoph Cullmann 2013-03-27 20:39:17 UTC
Uhg, I deleted that test now I guess :( If you want to adapt it to the new folding, plz recover it from commit 1e7df474b9d5d69e80428736176cbf22e81c2649
Comment 9 Dominik Haumann 2013-03-27 21:52:29 UTC
It may make sense since the crash is in the KateLayoueCache.
So if this bug was due to other bogus code unrelated to code folding, it makes sense to check this once.
Comment 10 Dominik Haumann 2013-04-11 21:53:20 UTC
Backtrace with new folding:

[KCrash Handler]
#6  0xb77a6424 in __kernel_vsyscall ()
#7  0xb57b831f in raise () from /lib/libc.so.6
#8  0xb57b9c03 in abort () from /lib/libc.so.6
#9  0xb5b65e5e in qt_message_output (msgType=QtFatalMsg, buf=0x884a670 "ASSERT: \"d\" in file /usr/include/ksharedptr.h, line 126") at global/qglobal.cpp:2323
#10 0xb5b66059 in qt_message (msgType=QtFatalMsg, msg=0xb5cefc54 "ASSERT: \"%s\" in file %s, line %d", ap=0xbfe498e4 "\025\337>\263\220\337>\263~") at global/qglobal.cpp:2369
#11 0xb5b66178 in qFatal (msg=msg@entry=0xb5cefc54 "ASSERT: \"%s\" in file %s, line %d") at global/qglobal.cpp:2552
#12 0xb5b661f5 in qt_assert (assertion=0xb33edf15 "d", file=0xb33edf90 "/usr/include/ksharedptr.h", line=126) at global/qglobal.cpp:2018
#13 0xb32b1b85 in KSharedPtr<KateLineLayout>::operator-> (this=0xbfe4993c) at /usr/include/ksharedptr.h:126
#14 0xb32b5deb in KateLayoutCache::textLayout (this=0x8a49758, realLine=5, _viewLine=-1) at /home/dh/kde/kate/part/render/katelayoutcache.cpp:355
#15 0xb33077ee in KateViewInternal::previousLayout (this=0x8a69a48) at /home/dh/kde/kate/part/view/kateviewinternal.cpp:1247
#16 0xb330855e in KateViewInternal::cursorUp (this=0x8a69a48, sel=false) at /home/dh/kde/kate/part/view/kateviewinternal.cpp:1415
#17 0xb32fe779 in KateView::up (this=0x897c850) at /home/dh/kde/kate/part/view/kateview.cpp:2610
Comment 11 Dominik Haumann 2013-04-11 22:20:18 UTC
Git commit 0d78fa1eed528a4e918552b08f171f243925bb1b by Dominik Haumann.
Committed on 12/04/2013 at 00:18.
Pushed by dhaumann into branch 'master'.

add folding test again

This test still crashes: The cursor is hidden in a folding
region. Moving the cursor crashes Kate.

M  +11   -0    tests/CMakeLists.txt
A  +5    -0    tests/data/bug311866.cpp     [License: UNKNOWN]  *
A  +79   -0    tests/katefoldingtest.cpp     [License: LGPL (v2+)]
A  +37   -0    tests/katefoldingtest.h     [License: LGPL (v2+)]

The files marked with a * at the end have a non valid license. Please read: http://techbase.kde.org/Policies/Licensing_Policy and use the headers which are listed at that page.


http://commits.kde.org/kate/0d78fa1eed528a4e918552b08f171f243925bb1b
Comment 12 uran238 2013-04-13 11:58:21 UTC
> A +5 -0 tests/data/bug311866.cpp [License: UNKNOWN] *

You can put that example under any license you want.
Comment 13 Dominik Haumann 2013-04-16 13:17:23 UTC
Created attachment 78960 [details]
possible fix

Make sure the cursor is at a valid text position after folding text.
Comment 14 Dominik Haumann 2013-04-16 13:19:36 UTC
Created attachment 78961 [details]
correct patch this time

move cursor if it is in a folded region.
Comment 15 Dominik Haumann 2013-04-16 13:29:18 UTC
Git commit 5888f4b7020115f9bf9b55ff12d33e212d4258f4 by Dominik Haumann.
Committed on 16/04/2013 at 15:29.
Pushed by dhaumann into branch 'master'.

make sure cursor stays visible/valid when text is folded

FIXED-IN: 4.11
Related: bug 200858

M  +9    -0    part/buffer/katetextfolding.cpp
M  +11   -1    part/buffer/katetextfolding.h
M  +9    -7    part/view/kateviewinternal.cpp

http://commits.kde.org/kate/5888f4b7020115f9bf9b55ff12d33e212d4258f4
Comment 16 Kevin Funk 2013-08-28 07:09:44 UTC
*** Bug 324146 has been marked as a duplicate of this bug. ***
Comment 17 Christoph Feck 2013-09-03 20:01:39 UTC
*** Bug 324468 has been marked as a duplicate of this bug. ***
Comment 18 Dominik Haumann 2013-10-08 09:18:30 UTC
*** Bug 325133 has been marked as a duplicate of this bug. ***
Comment 19 bill-auger 2015-02-27 03:05:59 UTC
Application: kate (3.13.3)
KDE Platform Version: 4.13.3
Qt Version: 4.8.6
Operating System: Linux 3.13.0-45-generic i686
Distribution: Trisquel GNU/Linux 7.0, Belenos

-- Information about the crash:

  - duplicate symptom as bug #311866 which is marked as resolved and closed as of 4.11 (oct 2013)
  - unfortunately at least on my platform the bug is still present (fresh install of trisquel)

-- What I was doing when the application crashed:

STEPS:
  - fold or fold-all via keybinding
  - move text cursor over folded zone via arrow keys
  - crash

NOTE: crash can generally be avoided by pressing PGUP/PGDN immediately after folding

SYSTEM:
kate:
  3.13.3 (4:4.13.3-0ubuntu0.1           from trisquel belenos-updates repo)
kde-runtime:
  4.13.3 (4:4.13.3-0ubuntu0.2+kxstudio1 from kxstudio trusty          repo)
os:
  trisquel 7.0
de:
  lxde

-- Additional notes:

this bug has existed for many years on both nix and windows
this is my first time reporting but it occurs very often
kate is my fav editor and this is the only grief that she has ever given me
so i would be happy to help any way i can to fix this for good
the crash handler/bug reporting GUI did not work for me
login timed out apparently but then the "back" button was disabled
the following is the backtrace it created:


The crash can be reproduced sometimes.

-- Backtrace:
Application: Kate (kate), signal: Segmentation fault
Using host libthread_db library "/lib/i386-linux-gnu/libthread_db.so.1".
[Current thread is 1 (Thread 0xb4d53740 (LWP 4719))]

Thread 4 (Thread 0xb0165b40 (LWP 4748)):
#0  0xb7764424 in __kernel_vsyscall ()
#1  0xb5efed4b in pthread_cond_wait@@GLIBC_2.3.2 () at ../nptl/sysdeps/unix/sysv/linux/i386/i686/../i486/pthread_cond_wait.S:187
#2  0xb76876ec in __pthread_cond_wait (cond=0xb05fc8d0, mutex=0xb05fc8b8) at forward.c:149
#3  0xb04f9c92 in ?? () from /usr/lib/i386-linux-gnu/libQtScript.so.4
#4  0xb04f9cdf in ?? () from /usr/lib/i386-linux-gnu/libQtScript.so.4
#5  0xb5efaf70 in start_thread (arg=0xb0165b40) at pthread_create.c:312
#6  0xb767a50e in clone () at ../sysdeps/unix/sysv/linux/i386/clone.S:129

Thread 3 (Thread 0xa259bb40 (LWP 4751)):
#0  0xb5e58d0e in ?? () from /lib/i386-linux-gnu/libglib-2.0.so.0
#1  0xb5e59118 in g_mutex_unlock () from /lib/i386-linux-gnu/libglib-2.0.so.0
#2  0xb5e13515 in g_main_context_release () from /lib/i386-linux-gnu/libglib-2.0.so.0
#3  0xb5e14390 in ?? () from /lib/i386-linux-gnu/libglib-2.0.so.0
#4  0xb5e1476b in g_main_loop_run () from /lib/i386-linux-gnu/libglib-2.0.so.0
#5  0xb29d036a in ?? () from /usr/lib/i386-linux-gnu/libgio-2.0.so.0
#6  0xb5e3a9aa in ?? () from /lib/i386-linux-gnu/libglib-2.0.so.0
#7  0xb5efaf70 in start_thread (arg=0xa259bb40) at pthread_create.c:312
#8  0xb767a50e in clone () at ../sysdeps/unix/sysv/linux/i386/clone.S:129

Thread 2 (Thread 0xa1a6bb40 (LWP 4792)):
#0  0xb7764424 in __kernel_vsyscall ()
#1  0xb7688192 in __GI___clock_gettime (clock_id=1, tp=0xa1a6aff8) at ../sysdeps/unix/clock_gettime.c:115
#2  0xb60f58cc in do_gettime (frac=0xa1a6aff0, sec=0xa1a6afe8) at tools/qelapsedtimer_unix.cpp:127
#3  qt_gettime () at tools/qelapsedtimer_unix.cpp:144
#4  0xb61de2a2 in updateCurrentTime (this=0x866bf7c) at kernel/qeventdispatcher_unix.cpp:354
#5  QTimerInfoList::timerWait (this=0x866bf7c, tm=...) at kernel/qeventdispatcher_unix.cpp:460
#6  0xb61dc82b in timerSourcePrepareHelper (src=<optimized out>, timeout=0xa1a6b0ec) at kernel/qeventdispatcher_glib.cpp:143
#7  0xb61dc8bd in timerSourcePrepare (source=0x866bf48, timeout=0xa1a6b0ec) at kernel/qeventdispatcher_glib.cpp:176
#8  0xb5e139b3 in g_main_context_prepare () from /lib/i386-linux-gnu/libglib-2.0.so.0
#9  0xb5e142df in ?? () from /lib/i386-linux-gnu/libglib-2.0.so.0
#10 0xb5e14528 in g_main_context_iteration () from /lib/i386-linux-gnu/libglib-2.0.so.0
#11 0xb61dc95f in QEventDispatcherGlib::processEvents (this=0x866b560, flags=...) at kernel/qeventdispatcher_glib.cpp:436
#12 0xb61ab823 in QEventLoop::processEvents (this=this@entry=0xa1a6b258, flags=...) at kernel/qeventloop.cpp:149
#13 0xb61abb49 in QEventLoop::exec (this=this@entry=0xa1a6b258, flags=...) at kernel/qeventloop.cpp:204
#14 0xb609823d in QThread::exec (this=this@entry=0x8669ee8) at thread/qthread.cpp:537
#15 0xb618bc44 in QInotifyFileSystemWatcherEngine::run (this=0x8669ee8) at io/qfilesystemwatcher_inotify.cpp:265
#16 0xb609ab6f in QThreadPrivate::start (arg=0x8669ee8) at thread/qthread_unix.cpp:349
#17 0xb5efaf70 in start_thread (arg=0xa1a6bb40) at pthread_create.c:312
#18 0xb767a50e in clone () at ../sysdeps/unix/sysv/linux/i386/clone.S:129

Thread 1 (Thread 0xb4d53740 (LWP 4719)):
[KCrash Handler]
#7  viewLineCount (this=0x0) at ../../part/render/katelinelayout.cpp:174
#8  KateLineLayout::viewLine (this=0x0, viewLine=viewLine@entry=-1) at ../../part/render/katelinelayout.cpp:180
#9  0xb075cc61 in KateLayoutCache::textLayout (this=0xd969320, realLine=414, _viewLine=-1) at ../../part/render/katelayoutcache.cpp:355
#10 0xb07aa713 in KateViewInternal::previousLayout (this=this@entry=0x8d434f0) at ../../part/view/kateviewinternal.cpp:1278
#11 0xb07b14db in KateViewInternal::cursorUp (this=0x8d434f0, sel=sel@entry=false) at ../../part/view/kateviewinternal.cpp:1446
#12 0xb0792519 in KateView::up (this=0x8c02aa8) at ../../part/view/kateview.cpp:2668
#13 0xb07a44ad in KateView::qt_static_metacall (_o=0x0, _id=-1332734644, _a=0xbf87d488, _c=<optimized out>) at ./kateview.moc:353
#14 0xb61c20f7 in QMetaObject::activate (sender=sender@entry=0xd915f68, m=m@entry=0xb756c718 <QAction::staticMetaObject>, local_signal_index=local_signal_index@entry=1, argv=argv@entry=0xbf87d488) at kernel/qobject.cpp:3539
#15 0xb6c0b72d in QAction::triggered (this=this@entry=0xd915f68, _t1=false) at .moc/release-shared/moc_qaction.cpp:276
#16 0xb6c0d324 in QAction::activate (this=this@entry=0xd915f68, event=event@entry=QAction::Trigger) at kernel/qaction.cpp:1257
#17 0xb6c0d4b0 in QAction::event (this=this@entry=0xd915f68, e=e@entry=0xbf87d7c8) at kernel/qaction.cpp:1183
#18 0xb64806fd in KAction::event (this=0xd915f68, event=0xbf87d7c8) at ../../kdeui/actions/kaction.cpp:131
#19 0xb6c127f4 in QApplicationPrivate::notify_helper (this=0x8090c10, receiver=0xd915f68, e=0xbf87d7c8) at kernel/qapplication.cpp:4567
#20 0xb6c192d3 in QApplication::notify (this=0xbf87e23c, receiver=receiver@entry=0xd915f68, e=e@entry=0xbf87d7c8) at kernel/qapplication.cpp:4353
#21 0xb656f1f4 in KApplication::notify (this=0xbf87e23c, receiver=0xd915f68, event=0xbf87d7c8) at ../../kdeui/kernel/kapplication.cpp:311
#22 0xb61ace4a in QCoreApplication::notifyInternal (this=0xbf87e23c, receiver=0xd915f68, event=event@entry=0xbf87d7c8) at kernel/qcoreapplication.cpp:953
#23 0xb6c4a8bb in sendEvent (event=0xbf87d7c8, receiver=<optimized out>) at ../../include/QtCore/../../src/corelib/kernel/qcoreapplication.h:231
#24 QShortcutMap::dispatchEvent (this=this@entry=0x8090cbc, e=e@entry=0xbf87dac8) at kernel/qshortcutmap.cpp:887
#25 0xb6c4aa3d in QShortcutMap::tryShortcutEvent (this=0x8090cbc, o=0x8d434f0, e=0xbf87dac8) at kernel/qshortcutmap.cpp:367
#26 0xb6c1aca8 in QApplication::notify (this=0xbf87e23c, receiver=receiver@entry=0x8d434f0, e=e@entry=0xbf87dac8) at kernel/qapplication.cpp:3991
#27 0xb656f1f4 in KApplication::notify (this=0xbf87e23c, receiver=0x8d434f0, event=0xbf87dac8) at ../../kdeui/kernel/kapplication.cpp:311
#28 0xb61ace4a in QCoreApplication::notifyInternal (this=0xbf87e23c, receiver=receiver@entry=0x8d434f0, event=event@entry=0xbf87dac8) at kernel/qcoreapplication.cpp:953
#29 0xb6c10c7d in sendSpontaneousEvent (event=0xbf87dac8, receiver=0x8d434f0) at ../../include/QtCore/../../src/corelib/kernel/qcoreapplication.h:234
#30 qt_sendSpontaneousEvent (receiver=0x8d434f0, event=event@entry=0xbf87dac8) at kernel/qapplication.cpp:5565
#31 0xb6cc4829 in QKeyMapper::sendKeyEvent (keyWidget=keyWidget@entry=0x8d434f0, grab=grab@entry=false, type=QEvent::KeyPress, code=16777235, modifiers=..., text=..., autorepeat=autorepeat@entry=false, count=1, nativeScanCode=nativeScanCode@entry=111, nativeVirtualKey=65362, nativeModifiers=nativeModifiers@entry=0) at kernel/qkeymapper_x11.cpp:1866
#32 0xb6cc4c18 in QKeyMapperPrivate::translateKeyEvent (this=0x80c0e08, keyWidget=keyWidget@entry=0x8d434f0, event=event@entry=0xbf87de3c, grab=grab@entry=false) at kernel/qkeymapper_x11.cpp:1836
#33 0xb6c9ada5 in QApplication::x11ProcessEvent (this=0xbf87e23c, event=event@entry=0xbf87de3c) at kernel/qapplication_x11.cpp:3642
#34 0xb6cc7524 in x11EventSourceDispatch (s=0x808f4a8, callback=0x0, user_data=0x0) at kernel/qguieventdispatcher_glib.cpp:146
#35 0xb5e141e3 in g_main_context_dispatch () from /lib/i386-linux-gnu/libglib-2.0.so.0
#36 0xb5e14468 in ?? () from /lib/i386-linux-gnu/libglib-2.0.so.0
#37 0xb5e14528 in g_main_context_iteration () from /lib/i386-linux-gnu/libglib-2.0.so.0
#38 0xb61dc93b in QEventDispatcherGlib::processEvents (this=this@entry=0x805fef0, flags=...) at kernel/qeventdispatcher_glib.cpp:434
#39 0xb6cc75de in QGuiEventDispatcherGlib::processEvents (this=0x805fef0, flags=...) at kernel/qguieventdispatcher_glib.cpp:204
#40 0xb61ab823 in QEventLoop::processEvents (this=this@entry=0xbf87e0f8, flags=...) at kernel/qeventloop.cpp:149
#41 0xb61abb49 in QEventLoop::exec (this=this@entry=0xbf87e0f8, flags=...) at kernel/qeventloop.cpp:204
#42 0xb61b18fe in QCoreApplication::exec () at kernel/qcoreapplication.cpp:1225
#43 0xb6c10a24 in QApplication::exec () at kernel/qapplication.cpp:3828
#44 0xb775d92d in kdemain (argc=2, argv=0xbf87e344) at ../../../kate/app/katemain.cpp:381
#45 0x0804854b in main (argc=2, argv=0xbf87e344) at kate_dummy.cpp:3

Possible duplicates by query: bug 341129, bug 330221, bug 327174, bug 325133, bug 324468.
Comment 20 bill-auger 2015-02-27 03:26:32 UTC
just thought to add that the cursor need not necessarily be inside a folded code block in order to reproduce as indicated in the title of this issue - i normally move cursor to last char of the file before fold-all and still is likely to crash if i forget to press PGUP after folding - the cursor often disappears just after folding