Bug 230708 - kate crashes when opening a session with sftp files
Summary: kate crashes when opening a session with sftp files
Status: RESOLVED DUPLICATE of bug 203774
Alias: None
Product: kate
Classification: Applications
Component: application (show other bugs)
Version: unspecified
Platform: Fedora RPMs Linux
: VHI crash
Target Milestone: ---
Assignee: KWrite Developers
URL:
Keywords:
: 234211 (view as bug list)
Depends on:
Blocks:
 
Reported: 2010-03-14 14:09 UTC by Jaak Simm
Modified: 2010-05-27 10:46 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jaak Simm 2010-03-14 14:09:54 UTC
Application: kate (3.4.0)
KDE Platform Version: 4.4.00 (KDE 4.4.0)
Qt Version: 4.6.2
Operating System: Linux 2.6.32.9-70.fc12.i686 i686
Distribution: "Fedora release 12 (Constantine)"

-- Information about the crash:
I edited some files through sftp in kate and these files were saved in a session. Then I closed kate and reopened it and chose to open that session again. Kate crashed. Reopening kate and choosing that session (containing only sftp files) crashes kate everytime. Opening other sessions works fine, but when switching from them to the sftp one, kate crashes, everytime.

I use ssh key (enabled by ssh-add), so no password is required for opening the files through sftp.

The crash can be reproduced every time.

 -- Backtrace:
Application: Kate (kate), signal: Segmentation fault
[Current thread is 1 (Thread 0xb76e97a0 (LWP 3911))]

Thread 2 (Thread 0xb5f61b70 (LWP 3912)):
#0  0x00c61416 in __kernel_vsyscall ()
#1  0x00418c45 in pthread_cond_wait@@GLIBC_2.3.2 () at ../nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S:122
#2  0x07782567 in QTWTF::TCMalloc_PageHeap::scavengerThread (this=0x78546c0) at ../3rdparty/javascriptcore/JavaScriptCore/wtf/FastMalloc.cpp:2304
#3  0x077825b2 in QTWTF::TCMalloc_PageHeap::runScavengerThread (context=0x78546c0) at ../3rdparty/javascriptcore/JavaScriptCore/wtf/FastMalloc.cpp:1438
#4  0x00414ab5 in start_thread (arg=<value optimized out>) at pthread_create.c:297
#5  0x0033fdce in clone () at ../sysdeps/unix/sysv/linux/i386/clone.S:130

Thread 1 (Thread 0xb76e97a0 (LWP 3911)):
[KCrash Handler]
#6  isValid (this=0x9c5c980, proxyIndex=...) at /usr/include/QtCore/qabstractitemmodel.h:77
#7  KateViewDocumentProxyModel::mapToSource (this=0x9c5c980, proxyIndex=...) at /usr/src/debug/kdesdk-4.4.0/kate/app/kateviewdocumentproxymodel.cpp:346
#8  0x03ed84eb in KateViewDocumentProxyModel::sort (this=0x9c5c980) at /usr/src/debug/kdesdk-4.4.0/kate/app/kateviewdocumentproxymodel.cpp:620
#9  0x03ed8f18 in KateViewDocumentProxyModel::opened (this=0x9c5c980, index=...) at /usr/src/debug/kdesdk-4.4.0/kate/app/kateviewdocumentproxymodel.cpp:216
#10 0x03eadb16 in KateMainWindow::slotWindowActivated (this=0x9c3d340) at /usr/src/debug/kdesdk-4.4.0/kate/app/katemainwindow.cpp:572
#11 0x03eb3285 in KateMainWindow::qt_metacall (this=0x9c3d340, _c=InvokeMetaMethod, _id=<value optimized out>, _a=0xbf9e983c)
    at /usr/src/debug/kdesdk-4.4.0/i686-redhat-linux-gnu/kate/app/katemainwindow.moc:181
#12 0x0476a5db in QMetaObject::metacall (object=0x9c3d340, cl=InvokeMetaMethod, idx=59, argv=0xbf9e983c) at kernel/qmetaobject.cpp:237
#13 0x047794af in QMetaObject::activate (sender=0x9c4c810, m=0x3ef5584, local_signal_index=1, argv=0x0) at kernel/qobject.cpp:3293
#14 0x03eb63c8 in KateViewManager::viewChanged (this=0x9c4c810) at /usr/src/debug/kdesdk-4.4.0/i686-redhat-linux-gnu/kate/app/kateviewmanager.moc:164
#15 0x03eb87d1 in KateViewManager::activateView (this=0x9c4c810, view=0x9cfc9b8) at /usr/src/debug/kdesdk-4.4.0/kate/app/kateviewmanager.cpp:462
#16 0x03eb9692 in KateViewManager::createView (this=0x9c4c810, doc=<value optimized out>) at /usr/src/debug/kdesdk-4.4.0/kate/app/kateviewmanager.cpp:301
#17 0x03ebbc93 in KateViewSpace::restoreConfig (this=0x9c544b8, viewMan=0x9c4c810, config=0x9954da0, groupname=...) at /usr/src/debug/kdesdk-4.4.0/kate/app/kateviewspace.cpp:252
#18 0x03eb72b7 in KateViewManager::restoreSplitter (this=0x9c4c810, configBase=0x9954da0, group=..., parent=0x9c4c810, viewConfGrp=...) at /usr/src/debug/kdesdk-4.4.0/kate/app/kateviewmanager.cpp:795
#19 0x03eba6ea in KateViewManager::restoreViewConfiguration (this=0x9c4c810, config=...) at /usr/src/debug/kdesdk-4.4.0/kate/app/kateviewmanager.cpp:701
#20 0x03eb13d1 in KateMainWindow::KateMainWindow (this=0x9c3d340, sconfig=0x9954da0, sgroup=..., __in_chrg=<value optimized out>, __vtt_parm=<value optimized out>)
    at /usr/src/debug/kdesdk-4.4.0/kate/app/katemainwindow.cpp:208
#21 0x03e988c3 in KateApp::newMainWindow (this=0xbf9ea354, sconfig_=0x9954da0, sgroup_=...) at /usr/src/debug/kdesdk-4.4.0/kate/app/kateapp.cpp:389
#22 0x03ec5c60 in KateSessionManager::activateSession (this=0x993ca58, session=..., closeLast=false, saveLast=false, loadNew=true) at /usr/src/debug/kdesdk-4.4.0/kate/app/katesession.cpp:341
#23 0x03ecae66 in KateSessionManager::chooseSession (this=0x993ca58) at /usr/src/debug/kdesdk-4.4.0/kate/app/katesession.cpp:484
#24 0x03e9a266 in KateApp::startupKate (this=0xbf9ea354) at /usr/src/debug/kdesdk-4.4.0/kate/app/kateapp.cpp:182
#25 0x03e9a658 in KateApp::initKate (this=0xbf9ea354) at /usr/src/debug/kdesdk-4.4.0/kate/app/kateapp.cpp:135
#26 0x03e9a8aa in KateApp::KateApp (this=0xbf9ea354, args=0x9815e10) at /usr/src/debug/kdesdk-4.4.0/kate/app/kateapp.cpp:72
#27 0x00afb475 in kdemain (argc=2, argv=0xbf9ea9f4) at /usr/src/debug/kdesdk-4.4.0/kate/app/katemain.cpp:373
#28 0x0804864c in main (argc=2, argv=0xbf9ea9f4) at /usr/src/debug/kdesdk-4.4.0/i686-redhat-linux-gnu/kate/app/kate_dummy.cpp:3

Reported using DrKonqi
Comment 1 Dominik Haumann 2010-03-14 21:13:45 UTC
related: bug #203774, bug #230426
Comment 2 Milian Wolff 2010-04-13 12:19:31 UTC
*** Bug 234211 has been marked as a duplicate of this bug. ***
Comment 3 Milian Wolff 2010-04-13 12:20:37 UTC
info from bug 234211:

> I using kate to edit files with the fish protocol.
> After I selected two files to open them, a bug appears, that there was a line
> without description on the opened files overview.
> Now kate crashes every time I start it.
Comment 4 Carli* Freudenberg 2010-04-15 15:27:08 UTC
Debug with <code>valgrind --track-origins=yes kate</code>

==15756== Invalid read of size 4
==15756==    at 0x40A60A4: KateViewDocumentProxyModel::sort() (kateviewdocumentproxymodel.cpp:620)
==15756==    by 0x40A6B07: KateViewDocumentProxyModel::opened(QModelIndex const&) (kateviewdocumentproxymodel.cpp:216)
==15756==    by 0x40754E4: KateMainWindow::slotWindowActivated() (katemainwindow.cpp:566)
==15756==    by 0x407A601: KateMainWindow::qt_metacall(QMetaObject::Call, int, void**) (katemainwindow.moc:181)
==15756==    by 0x57DBAFF: QMetaObject::metacall(QObject*, QMetaObject::Call, int, void**) (in /usr/lib/qt4/libQtCore.so.4.6.2)
==15756==  Address 0xa0628d4 is 0 bytes after a block of size 20 alloc'd
==15756==    at 0x402593F: malloc (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
==15756==    by 0x56C20BB: qMalloc(unsigned int) (in /usr/lib/qt4/libQtCore.so.4.6.2)
==15756==    by 0xBE9E3CAB: ???
==15756== 
==15756== Invalid read of size 4
==15756==    at 0x40A3371: KateViewDocumentProxyModel::mapToSource(QModelIndex const&) const (qabstractitemmodel.h:77)
==15756==    by 0x40A60B7: KateViewDocumentProxyModel::sort() (kateviewdocumentproxymodel.cpp:620)
==15756==    by 0x40A6B07: KateViewDocumentProxyModel::opened(QModelIndex const&) (kateviewdocumentproxymodel.cpp:216)
==15756==    by 0x40754E4: KateMainWindow::slotWindowActivated() (katemainwindow.cpp:566)
==15756==    by 0x407A601: KateMainWindow::qt_metacall(QMetaObject::Call, int, void**) (katemainwindow.moc:181)
==15756==    by 0x57DBAFF: QMetaObject::metacall(QObject*, QMetaObject::Call, int, void**) (in /usr/lib/qt4/libQtCore.so.4.6.2)
==15756==  Address 0x0 is not stack'd, malloc'd or (recently) free'd
==15756== 
KCrash: Application 'kate' crashing...
Warning: connect() failed: : No such file or directory
==15756== Warning: invalid file descriptor -1 in syscall write()
==15756== Warning: invalid file descriptor -1 in syscall write()
==15756== Warning: invalid file descriptor -1 in syscall read()
KCrash cannot reach kdeinit, launching directly.
Comment 5 Dominik Haumann 2010-05-08 01:03:47 UTC
might be fixed in gitorious with this commit (see bug# 213014):
http://gitorious.org/kate/kate/commit/f6702b275e3f50f4cbe6dbf8755db36fef5b7319

Can you build Kate from gitorious and try again?
http://gitorious.org/kate/pages/Building%20Kate
Comment 6 Jaak Simm 2010-05-08 12:06:51 UTC
Compiled the latest git (nice guide btw), but still crashes:


Application: Kate (kate), signal: Aborted
[KCrash Handler]
#6  0x00e83416 in __kernel_vsyscall ()
#7  0x0017ea81 in raise () from /lib/libc.so.6
#8  0x0018034a in abort () from /lib/libc.so.6
#9  0x058287ec in qt_message_output(QtMsgType, char const*) () from /usr/lib/libQtCore.so.4
#10 0x058289cc in ?? () from /usr/lib/libQtCore.so.4
#11 0x05828aea in qFatal(char const*, ...) () from /usr/lib/libQtCore.so.4
#12 0x05828b2d in qt_assert_x(char const*, char const*, char const*, int) () from /usr/lib/libQtCore.so.4
#13 0x005d1bbe in QList<int>::operator[] (this=0x9e022f8, i=1) at /usr/include/QtCore/qlist.h:447
#14 0x005ec16a in KateViewDocumentProxyModel::sort (this=0x9e022d0) at /home/jr/kde/kate/kate/app/kateviewdocumentproxymodel.cpp:639
#15 0x005ebbc0 in KateViewDocumentProxyModel::setSortRole (this=0x9e022d0, role=0) at /home/jr/kde/kate/kate/app/kateviewdocumentproxymodel.cpp:609
#16 0x005bf91a in KateFileList::setSortRole (this=0x9c9dd48, role=0) at /home/jr/kde/kate/kate/app/katefilelist.cpp:174
#17 0x005c3a28 in KateMainWindow::KateMainWindow (this=0x9e2e990, sconfig=0x9a93d80, sgroup=..., __in_chrg=<value optimized out>, __vtt_parm=<value optimized out>)
    at /home/jr/kde/kate/kate/app/katemainwindow.cpp:206
#18 0x005b0251 in KateApp::newMainWindow (this=0xbfc6e42c, sconfig_=0x9a93d80, sgroup_=...) at /home/jr/kde/kate/kate/app/kateapp.cpp:390
#19 0x005dbc35 in KateSessionManager::activateSession (this=0x9b13028, session=..., closeLast=false, saveLast=false, loadNew=true) at /home/jr/kde/kate/kate/app/katesession.cpp:341
#20 0x005dc9d0 in KateSessionManager::chooseSession (this=0x9b13028) at /home/jr/kde/kate/kate/app/katesession.cpp:484
#21 0x005aeea1 in KateApp::startupKate (this=0xbfc6e42c) at /home/jr/kde/kate/kate/app/kateapp.cpp:182
#22 0x005ae883 in KateApp::initKate (this=0xbfc6e42c) at /home/jr/kde/kate/kate/app/kateapp.cpp:135
#23 0x005ae1dc in KateApp::KateApp (this=0xbfc6e42c, args=0x9947e00) at /home/jr/kde/kate/kate/app/kateapp.cpp:72
#24 0x00f6d6cc in kdemain (argc=1, argv=0xbfc6eac4) at /home/jr/kde/kate/kate/app/katemain.cpp:373
#25 0x08048689 in main (argc=1, argv=0xbfc6eac4) at /home/jr/kde/build/kate/app/kate_dummy.cpp:3
Comment 7 Milian Wolff 2010-05-27 00:04:34 UTC
is this related to 203774? might be fixed, please try with current git version of kate and tell us whether the problem persists.
Comment 8 Dominik Haumann 2010-05-27 00:12:15 UTC
yes, fixed for kde >= 4.4.4.

@Jaak: if you "git pull" and recompile with `make install` the crash should be gone.

*** This bug has been marked as a duplicate of bug 203774 ***
Comment 9 Johannes Schwenk 2010-05-27 09:34:18 UTC
This is fixed for me in the newest git version! Thank you very much! This makes work so much easier!

Note:
Could build kate easiliy with instructions found here http://dhaumann.blogspot.com/2010/04/quick-compiling-kate-in-stable-kde.html
Comment 10 Dominik Haumann 2010-05-27 10:46:15 UTC
@Johannes: Better use http://gitorious.org/kate/pages/Building%20Kate. This is identical to your link, but contains a little fix: It's debugfull instead of fulldebug :)