Bug 269559

Summary: Crash when attempting to open a new investment transaction
Product: [Applications] kmymoney Reporter: allan <agander93>
Component: generalAssignee: KMyMoney Devel Mailing List <kmymoney-devel>
Status: RESOLVED FIXED    
Severity: crash    
Priority: NOR    
Version: SVN   
Target Milestone: ---   
Platform: Compiled Sources   
OS: Linux   
Latest Commit: Version Fixed In:

Description allan 2011-03-27 18:46:40 UTC
Application: kmymoney (4.5.90-svn1225922)
KDE Platform Version: 4.6.00 (4.6.0) "release 6" (Compiled from sources)
Qt Version: 4.7.1
Operating System: Linux 2.6.37.1-1.2-desktop x86_64
Distribution: "openSUSE 11.4 (x86_64)"

-- Information about the crash:
- What I was doing when the application crashed:
I had earlier removed some prices that were invalid, discovered on creating an investment performance report.  Then I examined some accounts and decided to enter a sell transaction.  Whether I hit the wrong button, I don't know, but the ledger was showing the latest transaction,  opened for editing.  Cancel wasn't enabled, nor accept. (I don't use the transaction form.)  I hit escape and KMM crashed.  I can't now be certain that the crash immediately followed the escape key use.

-- Backtrace:
Application: KMyMoney (kmymoney), signal: Segmentation fault
[Current thread is 1 (Thread 0x7fcd41070760 (LWP 8698))]

Thread 2 (Thread 0x7fcd23bee700 (LWP 9655)):
#0  0x00007fff4f1ff851 in clock_gettime ()
#1  0x00007fcd366832b3 in clock_gettime () from /lib64/librt.so.1
#2  0x00007fcd3d3282b2 in ?? () from /usr/lib64/libQtCore.so.4
#3  0x00007fcd3d3eb33d in ?? () from /usr/lib64/libQtCore.so.4
#4  0x00007fcd3d3eb6b5 in ?? () from /usr/lib64/libQtCore.so.4
#5  0x00007fcd3d3ea17c in ?? () from /usr/lib64/libQtCore.so.4
#6  0x00007fcd3d3ea225 in ?? () from /usr/lib64/libQtCore.so.4
#7  0x00007fcd363d2087 in g_main_context_prepare () from /lib64/libglib-2.0.so.0
#8  0x00007fcd363d2fa9 in ?? () from /lib64/libglib-2.0.so.0
#9  0x00007fcd363d3650 in g_main_context_iteration () from /lib64/libglib-2.0.so.0
#10 0x00007fcd3d3ea976 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib64/libQtCore.so.4
#11 0x00007fcd3d3bf052 in QEventLoop::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib64/libQtCore.so.4
#12 0x00007fcd3d3bf265 in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib64/libQtCore.so.4
#13 0x00007fcd3d2d41e4 in QThread::exec() () from /usr/lib64/libQtCore.so.4
#14 0x00007fcd3d3a0968 in ?? () from /usr/lib64/libQtCore.so.4
#15 0x00007fcd3d2d6a5e in ?? () from /usr/lib64/libQtCore.so.4
#16 0x00007fcd3e49ea3f in start_thread () from /lib64/libpthread.so.0
#17 0x00007fcd3b93a67d in clone () from /lib64/libc.so.6
#18 0x0000000000000000 in ?? ()

Thread 1 (Thread 0x7fcd41070760 (LWP 8698)):
[KCrash Handler]
#6  0x0000000000000030 in ?? () at /usr/include/QtCore/qstring.h:883
#7  0x00007fcd3d3d4685 in QObject::disconnect(QObject const*, char const*, QObject const*, char const*) () from /usr/lib64/libQtCore.so.4
#8  0x00000000006be5bc in disconnect (this=0xa807800, __in_chrg=<value optimized out>) at /usr/include/QtCore/qobject.h:229
#9  TransactionEditor::~TransactionEditor (this=0xa807800, __in_chrg=<value optimized out>) at /home/aga/CSV/kmymoney/kmymoney/dialogs/transactioneditor.cpp:86
#10 0x000000000063e599 in InvestTransactionEditor::~InvestTransactionEditor (this=0xa807800, __in_chrg=<value optimized out>) at /home/aga/CSV/kmymoney/kmymoney/dialogs/investtransactioneditor.cpp:96
#11 0x0000000000485679 in deleteTransactionEditor (this=0xc7d2e0) at /home/aga/CSV/kmymoney/kmymoney/kmymoney.cpp:5134
#12 KMyMoneyApp::slotTransactionsCancel (this=0xc7d2e0) at /home/aga/CSV/kmymoney/kmymoney/kmymoney.cpp:5175
#13 0x00000000004a016d in KMyMoneyApp::qt_metacall (this=0xc7d2e0, _c=QMetaObject::InvokeMetaMethod, _id=79, _a=0x7fff4f13f260) at /home/aga/CSV/kmymoney/build/kmymoney/kmymoney.moc:482
#14 0x00007fcd3d3d4def in QMetaObject::activate(QObject*, QMetaObject const*, int, void**) () from /usr/lib64/libQtCore.so.4
#15 0x00007fcd3c50d982 in QAction::triggered(bool) () from /usr/lib64/libQtGui.so.4
#16 0x00007fcd3c50db7a in QAction::activate(QAction::ActionEvent) () from /usr/lib64/libQtGui.so.4
#17 0x00007fcd3c8c831a in ?? () from /usr/lib64/libQtGui.so.4
#18 0x00007fcd3c8c85cc in QAbstractButton::mouseReleaseEvent(QMouseEvent*) () from /usr/lib64/libQtGui.so.4
#19 0x00007fcd3c984a7a in QToolButton::mouseReleaseEvent(QMouseEvent*) () from /usr/lib64/libQtGui.so.4
#20 0x00007fcd3c565538 in QWidget::event(QEvent*) () from /usr/lib64/libQtGui.so.4
#21 0x00007fcd3c513d14 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /usr/lib64/libQtGui.so.4
#22 0x00007fcd3c51caac in QApplication::notify(QObject*, QEvent*) () from /usr/lib64/libQtGui.so.4
#23 0x00007fcd3f60f9e6 in KApplication::notify(QObject*, QEvent*) () from /usr/lib64/libkdeui.so.5
#24 0x00007fcd3d3bfbfc in QCoreApplication::notifyInternal(QObject*, QEvent*) () from /usr/lib64/libQtCore.so.4
#25 0x00007fcd3c514d25 in QApplicationPrivate::sendMouseEvent(QWidget*, QMouseEvent*, QWidget*, QWidget*, QWidget**, QPointer<QWidget>&, bool) () from /usr/lib64/libQtGui.so.4
#26 0x00007fcd3c592e08 in ?? () from /usr/lib64/libQtGui.so.4
#27 0x00007fcd3c5914c9 in QApplication::x11ProcessEvent(_XEvent*) () from /usr/lib64/libQtGui.so.4
#28 0x00007fcd3c5b90f2 in ?? () from /usr/lib64/libQtGui.so.4
#29 0x00007fcd363d2bd3 in g_main_context_dispatch () from /lib64/libglib-2.0.so.0
#30 0x00007fcd363d33b0 in ?? () from /lib64/libglib-2.0.so.0
#31 0x00007fcd363d3650 in g_main_context_iteration () from /lib64/libglib-2.0.so.0
#32 0x00007fcd3d3ea91f in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib64/libQtCore.so.4
#33 0x00007fcd3c5b8d8e in ?? () from /usr/lib64/libQtGui.so.4
#34 0x00007fcd3d3bf052 in QEventLoop::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib64/libQtCore.so.4
#35 0x00007fcd3d3bf265 in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib64/libQtCore.so.4
#36 0x00007fcd3d3c36ab in QCoreApplication::exec() () from /usr/lib64/libQtCore.so.4
#37 0x000000000045a31e in main (argc=1, argv=0x7fff4f141448) at /home/aga/CSV/kmymoney/kmymoney/main.cpp:260

Possible duplicates by query: bug 263361, bug 259916, bug 240285.

Reported using DrKonqi
Comment 1 allan 2011-03-27 19:28:34 UTC
Another crash, which appears to be identical.
More info.
The account in which I wanted to create a new transaction had been closed for a while, the last transaction being a 'remove shares'.  In fact, the security had been merged into another security, by the investment company, and I had added a new security for this new security. I found that because the shares had been 'removed', there was no performance history, do I decided to add a new transaction, to sell the shares, and then to delete the 'remove shares' item.

This time, on opening the ledger, only the 'new' button was active.  I started to enter the sell transaction, but was informed that the security did not exist in that account, and I was asked if I wanted to add it.  I declined.  Looking in  Investment view, the security was showing.  I went through the edit procedure without making any changes, then went back to Ledger view.  Now, it looks OK.  No, wait.  If I use the button to create the transaction, all is well.  If I right click, instead of opening a new item, it reopens the last one.  There's no Cancel button, so I click another item and am asked if I wan't to cancel editing.  I click yes, and the transaction closes, but not properly.  It appears to be overlapping the previous transaction.  Now the cancel button is back, and when I click it, KMM crashes.
Comment 2 allan 2011-03-27 21:02:12 UTC
Another crash, but not identical.  Here's the BT in case it helps.


Application: KMyMoney (kmymoney), signal: Segmentation fault
[KCrash Handler]
#6  0x00007f5d6bedc3e9 in QWidget::setFocus(Qt::FocusReason) () from /usr/lib64/libQtGui.so.4
#7  0x00000000006452f0 in setFocus (this=0x2b5d8f0, categoryWidgetName=<value optimized out>, amountWidgetName=<value optimized out>, splits=<value optimized out>, isIncome=true, slotEditSplits=0x88561c "1slotEditInterestSplits()") at /usr/include/QtGui/qwidget.h:422
#8  InvestTransactionEditor::editSplits (this=0x2b5d8f0, categoryWidgetName=<value optimized out>, amountWidgetName=<value optimized out>, splits=<value optimized out>, isIncome=true, slotEditSplits=0x88561c "1slotEditInterestSplits()") at /home/aga/CSV/kmymoney/kmymoney/dialogs/investtransactioneditor.cpp:416
#9  0x00000000006456a8 in InvestTransactionEditor::slotEditInterestSplits (this=0x2b5d8f0) at /home/aga/CSV/kmymoney/kmymoney/dialogs/investtransactioneditor.cpp:339
#10 0x00000000006458d8 in InvestTransactionEditor::qt_metacall (this=0x2b5d8f0, _c=QMetaObject::InvokeMetaMethod, _id=3, _a=0x7fff941acbf0) at /home/aga/CSV/kmymoney/build/kmymoney/dialogs/investtransactioneditor.moc:99
#11 0x00007f5d6cd58def in QMetaObject::activate(QObject*, QMetaObject const*, int, void**) () from /usr/lib64/libQtCore.so.4
#12 0x00007f5d6c502a32 in QAbstractButton::clicked(bool) () from /usr/lib64/libQtGui.so.4
#13 0x00007f5d6c24ad9b in ?? () from /usr/lib64/libQtGui.so.4
#14 0x00007f5d6c24c35b in ?? () from /usr/lib64/libQtGui.so.4
#15 0x00007f5d6c24c5cc in QAbstractButton::mouseReleaseEvent(QMouseEvent*) () from /usr/lib64/libQtGui.so.4
#16 0x00007f5d6bee9538 in QWidget::event(QEvent*) () from /usr/lib64/libQtGui.so.4
#17 0x00007f5d6be97d14 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /usr/lib64/libQtGui.so.4
#18 0x00007f5d6bea0aac in QApplication::notify(QObject*, QEvent*) () from /usr/lib64/libQtGui.so.4
#19 0x00007f5d6ef939e6 in KApplication::notify(QObject*, QEvent*) () from /usr/lib64/libkdeui.so.5
#20 0x00007f5d6cd43bfc in QCoreApplication::notifyInternal(QObject*, QEvent*) () from /usr/lib64/libQtCore.so.4
#21 0x00007f5d6be98d25 in QApplicationPrivate::sendMouseEvent(QWidget*, QMouseEvent*, QWidget*, QWidget*, QWidget**, QPointer<QWidget>&, bool) () from /usr/lib64/libQtGui.so.4
#22 0x00007f5d6bf16e08 in ?? () from /usr/lib64/libQtGui.so.4
#23 0x00007f5d6bf154c9 in QApplication::x11ProcessEvent(_XEvent*) () from /usr/lib64/libQtGui.so.4
#24 0x00007f5d6bf3d0f2 in ?? () from /usr/lib64/libQtGui.so.4
#25 0x00007f5d65d56bd3 in g_main_context_dispatch () from /lib64/libglib-2.0.so.0
#26 0x00007f5d65d573b0 in ?? () from /lib64/libglib-2.0.so.0
#27 0x00007f5d65d57650 in g_main_context_iteration () from /lib64/libglib-2.0.so.0
#28 0x00007f5d6cd6e91f in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib64/libQtCore.so.4
#29 0x00007f5d6bf3cd8e in ?? () from /usr/lib64/libQtGui.so.4
#30 0x00007f5d6cd43052 in QEventLoop::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib64/libQtCore.so.4
#31 0x00007f5d6cd43265 in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib64/libQtCore.so.4
#32 0x00007f5d6cd476ab in QCoreApplication::exec() () from /usr/lib64/libQtCore.so.4
#33 0x000000000045a31e in main (argc=1, argv=0x7fff941aedc8) at /home/aga/CSV/kmymoney/kmymoney/main.cpp:260

This occurred when the Ledger was showing the wrongly formatted 'new' transaction from above.  I was checking which fields might still be active. I got the split dialog up OK, but then the crash.  Of course it may be that things were already corrupt, but as I say the BT could be useful.
Comment 3 Thomas Baumgart 2011-06-04 10:06:04 UTC
Is the problem still persistent in newer trunk versions?
Comment 4 Thomas Baumgart 2011-07-05 17:28:44 UTC
No answer so far to my last entry.
Comment 5 allan 2011-07-05 18:57:33 UTC
(In reply to comment #4)
> No answer so far to my last entry.

Apologies, I missed that.  There were a few similar/identical issues on the go at the same time.

I've seen no similar problem for several weeks and am pretty sure it's fixed.