Skip to content
This repository has been archived by the owner on Sep 1, 2021. It is now read-only.

(master) Crash when deleting atoms with bond dialog open #554

Open
cryos opened this issue Nov 9, 2010 · 11 comments
Open

(master) Crash when deleting atoms with bond dialog open #554

cryos opened this issue Nov 9, 2010 · 11 comments

Comments

@cryos
Copy link
Owner

cryos commented Nov 9, 2010

This may be a problem with other property dialogs, too. It seems to only crash when an atom is deleted, e.g. adding new atoms works fine.

To reproduce:

  1. Build ethane
  2. Open bond properties dialog
  3. Using the draw tool, click on a hydrogen
  4. Crash...

Reported by: @dlonie

@cryos
Copy link
Owner Author

cryos commented Nov 9, 2010

Cannot reproduce in 1.0.x

Original comment by: @annulen

@cryos
Copy link
Owner Author

cryos commented Nov 9, 2010

Works fine - I remove atoms, and bonds disappear in the dialog. I will check master later

Original comment by: @annulen

@cryos
Copy link
Owner Author

cryos commented Nov 11, 2010

Cannot reproduce for master

Original comment by: @annulen

@cryos
Copy link
Owner Author

cryos commented Nov 11, 2010

I'm still seeing it on master -- I've included a backtrace. This is with Qt 4.7.1.

#0 0xb7fe1424 in __kernel_vsyscall ()
#1 0xb7e93de1 in raise () from /lib/libc.so.6
#2 0xb7e9566e in abort () from /lib/libc.so.6
#3 0xb6d296c3 in qt_message_output (msgType=QtFatalMsg,
buf=0x87afc00 "ASSERT failure in QVector::at: "index out of range", file ../../include/QtCore/../../../qt-git/src/corelib/tools/qvector.h, line 339")
at /usr/src/qt-git/src/corelib/global/qglobal.cpp:2282
#4 0xb6d2982e in qt_message (msgType=QtFatalMsg, msg=0xb6eb4818 "ASSERT failure in %s: "%s", file %s, line %d", ap=0xbfffdb04 "\v袷\341碷\240碷S\001")
at /usr/src/qt-git/src/corelib/global/qglobal.cpp:2328
#5 0xb6d29c5a in qFatal (msg=0xb6eb4818 "ASSERT failure in %s: "%s", file %s, line %d") at /usr/src/qt-git/src/corelib/global/qglobal.cpp:2511
#6 0xb6d292aa in qt_assert_x (where=0xb7a2e80b "QVector::at", what=0xb7a2e7e1 "index out of range",
file=0xb7a2e7a0 "../../include/QtCore/../../../qt-git/src/corelib/tools/qvector.h", line=339) at /usr/src/qt-git/src/corelib/global/qglobal.cpp:2035
#7 0xb72c83ed in QVector::at (this=0x8788c24, i=6) at ../../include/QtCore/../../../qt-git/src/corelib/tools/qvector.h:339
#8 0xb791dba2 in QSortFilterProxyModelPrivate::_q_sourceDataChanged (this=0x8788cf0, source_top_left=..., source_bottom_right=...)
at /usr/src/qt-git/src/gui/itemviews/qsortfilterproxymodel.cpp:1187
#9 0xb7921fc9 in QSortFilterProxyModel::qt_metacall (this=0x8788ce0, _c=QMetaObject::InvokeMetaMethod, _id=5, _a=0xbfffdd74)
at .moc/debug-shared/moc_qsortfilterproxymodel.cpp:128
#10 0xb6e454a2 in QMetaObject::metacall (object=0x8788ce0, cl=QMetaObject::InvokeMetaMethod, idx=30, argv=0xbfffdd74) at /usr/src/qt-git/src/corelib/kernel/qmetaobject.cpp:237
#11 0xb6e583f1 in QMetaObject::activate (sender=0x8770ae8, m=0x8115d20, local_signal_index=0, argv=0xbfffdd74) at /usr/src/qt-git/src/corelib/kernel/qobject.cpp:3272
#12 0xb6eaf94d in QAbstractItemModel::dataChanged (this=0x8770ae8, _t1=..., _t2=...) at .moc/debug-shared/moc_qabstractitemmodel.cpp:148
#13 0xb14edadb in Avogadro::PropertiesModel::updateTable (this=0x8770ae8) at /git/avogadro/libavogadro/src/extensions/propmodel.cpp:823
#14 0xb14f5b97 in Avogadro::PropertiesModel::qt_metacall (this=0x8770ae8, _c=QMetaObject::InvokeMetaMethod, _id=0, _a=0xbfffde9c)
at /git/avogadro/build/libavogadro/src/extensions/moc_propmodel.cxx:80
#15 0xb6e454a2 in QMetaObject::metacall (object=0x8770ae8, cl=QMetaObject::InvokeMetaMethod, idx=24, argv=0xbfffde9c) at /usr/src/qt-git/src/corelib/kernel/qmetaobject.cpp:237
#16 0xb6e583f1 in QMetaObject::activate (sender=0x85dca20, m=0xb6895298, local_signal_index=0, argv=0x0) at /usr/src/qt-git/src/corelib/kernel/qobject.cpp:3272
#17 0xb67e896b in Avogadro::Primitive::updated (this=0x85dca20) at /git/avogadro/build/libavogadro/src/primitive.moc:143
#18 0xb6792f9b in Avogadro::Molecule::update (this=0x85dca20) at /git/avogadro/libavogadro/src/molecule.cpp:1084
#19 0xb124fafb in Avogadro::ChangeElementDrawCommand::redo (this=0x87b0400) at /git/avogadro/libavogadro/src/tools/drawcommand.cpp:915
#20 0xb79ffe9f in QUndoStack::push (this=0x8240e10, cmd=0x87b0400) at /usr/src/qt-git/src/gui/util/qundostack.cpp:541
#21 0xb677908f in Avogadro::GLWidget::mouseReleaseEvent (this=0x8246288, event=0xbfffe77c) at /git/avogadro/libavogadro/src/glwidget.cpp:1102
#22 0xb7300459 in QWidget::event (this=0x8246288, event=0xbfffe77c) at /usr/src/qt-git/src/gui/kernel/qwidget.cpp:8200
#23 0xb7d81472 in QGLWidget::event (this=0x8246288, e=0xbfffe77c) at /usr/src/qt-git/src/opengl/qgl.cpp:4221
#24 0xb6778e72 in Avogadro::GLWidget::event (this=0x8246288, event=0xbfffe77c) at /git/avogadro/libavogadro/src/glwidget.cpp:1062
#25 0xb72a0426 in QApplicationPrivate::notify_helper (this=0x8147358, receiver=0x8246288, e=0xbfffe77c) at /usr/src/qt-git/src/gui/kernel/qapplication.cpp:4451
#26 0xb729e5b7 in QApplication::notify (this=0xbffff050, receiver=0x8246288, e=0xbfffe77c) at /usr/src/qt-git/src/gui/kernel/qapplication.cpp:4012
#27 0xb6e3ddf7 in QCoreApplication::notifyInternal (this=0xbffff050, receiver=0x8246288, event=0xbfffe77c) at /usr/src/qt-git/src/corelib/kernel/qcoreapplication.cpp:732
#28 0xb72a2d03 in QCoreApplication::sendSpontaneousEvent (receiver=0x8246288, event=0xbfffe77c) at ../../include/QtCore/../../../qt-git/src/corelib/kernel/qcoreapplication.h:218
#29 0xb729cce3 in QApplicationPrivate::sendMouseEvent (receiver=0x8246288, event=0xbfffe77c, alienWidget=0x0, nativeWidget=0x8246288, buttonDown=0xb7d542c0,
lastMouseReceiver=..., spontaneous=true) at /usr/src/qt-git/src/gui/kernel/qapplication.cpp:3109
#30 0xb7336542 in QETWidget::translateMouseEvent (this=0x8246288, event=0xbfffecb0) at /usr/src/qt-git/src/gui/kernel/qapplication_x11.cpp:4437
#31 0xb7333188 in QApplication::x11ProcessEvent (this=0xbffff050, event=0xbfffecb0) at /usr/src/qt-git/src/gui/kernel/qapplication_x11.cpp:3441
#32 0xb73683fa in x11EventSourceDispatch (s=0x814b0e8, callback=0, user_data=0x0) at /usr/src/qt-git/src/gui/kernel/qguieventdispatcher_glib.cpp:146
#33 0xb622bb72 in g_main_context_dispatch () from /usr/lib/libglib-2.0.so.0
#34 0xb622c350 in ?? () from /usr/lib/libglib-2.0.so.0
#35 0xb622c604 in g_main_context_iteration () from /usr/lib/libglib-2.0.so.0
#36 0xb6e723ac in QEventDispatcherGlib::processEvents (this=0x8147f28, flags=...) at /usr/src/qt-git/src/corelib/kernel/qeventdispatcher_glib.cpp:415
#37 0xb7368750 in QGuiEventDispatcherGlib::processEvents (this=0x8147f28, flags=...) at /usr/src/qt-git/src/gui/kernel/qguieventdispatcher_glib.cpp:204
#38 0xb6e3bb55 in QEventLoop::processEvents (this=0xbfffef5c, flags=...) at /usr/src/qt-git/src/corelib/kernel/qeventloop.cpp:149
#39 0xb6e3bc99 in QEventLoop::exec (this=0xbfffef5c, flags=...) at /usr/src/qt-git/src/corelib/kernel/qeventloop.cpp:201
#40 0xb6e3e4e2 in QCoreApplication::exec () at /usr/src/qt-git/src/corelib/kernel/qcoreapplication.cpp:1009
#41 0xb729d954 in QApplication::exec () at /usr/src/qt-git/src/gui/kernel/qapplication.cpp:3725
#42 0x0806c1dd in main (argc=1, argv=0xbffff214) at /git/avogadro/avogadro/src/main.cpp:245

Original comment by: @dlonie

@cryos
Copy link
Owner Author

cryos commented Nov 11, 2010

Is "Adjust Hydrogens" enabled or disabled?

I'm using Qt 4.6.2, can test 4.7.1 if it matters

Original comment by: @annulen

@cryos
Copy link
Owner Author

cryos commented Nov 11, 2010

Enabled, but I get the crash either way.

Original comment by: @dlonie

@cryos
Copy link
Owner Author

cryos commented Nov 11, 2010

Cannot reproduce with master and Qt 4.7.1. I also can trigger known bug related to undo, but I delete atoms without any problems, and they disappaer from table

Original comment by: @annulen

@cryos
Copy link
Owner Author

cryos commented Nov 12, 2010

Maybe you have checked out "change 257 " (Fix the setOB* functions to call update()) in your master?

Original comment by: @annulen

@cryos
Copy link
Owner Author

cryos commented Nov 12, 2010

Nope, this is on gerrit/master. I thought it might have been a qt problem (I was running 4.7-stable from gitorious, but I'm seeing the same behavior with 4.7.1).

I can't reproduce this on my coworker's box either. Leave this open until I have a chance to figure out what's wrong on my machine, and if it's not an Avogadro problem I'll close it.

Dave

Original comment by: @dlonie

@cryos
Copy link
Owner Author

cryos commented Apr 7, 2011

Just want to separate this from 1.0 bugs.

Original comment by: @ghutchis

@cryos
Copy link
Owner Author

cryos commented Apr 7, 2011

Just a quick update -- I can still reproduce this consistently on master, even though I've reinstalled my OS since reporting this. Compiler is gcc 4.5.2 on arch linux x86_64.

My guess is a missing blockSignals somewhere...I don't know when I'll find time to dig around on this, so if anyone else is interested, feel free :-)

Original comment by: *anonymous

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants