Clicking on a MenuItem can cause segfault

Issue #282 resolved
Paul Turner
created an issue

Ref: http://www.cegui.org.uk/phpBB2/viewtopic.php?t=3734

When clicking on a MenuItem, it seems that the OnMouseLeavesMenuItem() event is processed first (which closes the popup menu) and returns fine. After that a segfault occures. My OnMenuItemClicked() call-back method is never called.

Reproducibility: have not tried

Additional information: Program terminated with signal 11, Segmentation fault.

  1. 0 0xb7876dd3 in CEGUI::MenuBase::changePopupMenuItem () from /usr/lib/libCEGUIBase.so.1 (gdb) bt
  2. 0 0xb7876dd3 in CEGUI::MenuBase::changePopupMenuItem () from /usr/lib/libCEGUIBase.so.1
  3. 1 0xb787838e in CEGUI::MenuItem::closePopupMenu () from /usr/lib/libCEGUIBase.so.1
  4. 2 0xb78785d8 in CEGUI::MenuItem::closeAllMenuItemPopups () from /usr/lib/libCEGUIBase.so.1
  5. 3 0xb78786dc in CEGUI::MenuItem::onClicked () from /usr/lib/libCEGUIBase.so.1
  6. 4 0xb7877fab in CEGUI::MenuItem::onMouseButtonUp () from /usr/lib/libCEGUIBase.so.1
  7. 5 0xb77fabb9 in CEGUI::System::injectMouseButtonUp () from /usr/lib/libCEGUIBase.so.1
  8. 6 0x0805bb0d in AO::Application::mouseReleased (this=0xbfc5a150, mEvt=@0xbfc59f9c, butId=OIS::MB_Left) at [...]/src/Application.cpp:553
  9. 7 0xb7f171a4 in OIS::LinuxMouse::_processXEvents () from /usr/lib/libOIS-1.2.0.so
  10. 8 0xb7f17423 in OIS::LinuxMouse::capture () from /usr/lib/libOIS-1.2.0.so
  11. 9 0x0805c376 in AO::Application::frameStarted (this=0xbfc5a150, fEvt=@0xbfc5a0a4) at [...]/src/Application.cpp:351
  12. 10 0xb7cbe164 in Ogre::Root::_fireFrameStarted () from /usr/lib/libOgreMain-1.6.1.so
  13. 11 0xb7cbe927 in Ogre::Root::_fireFrameStarted () from /usr/lib/libOgreMain-1.6.1.so
  14. 12 0xb7cbe962 in Ogre::Root::renderOneFrame () from /usr/lib/libOgreMain-1.6.1.so
  15. 13 0xb7cbe9e1 in Ogre::Root::startRendering () from /usr/lib/libOgreMain-1.6.1.so
  16. 14 0x0805c46c in AO::Application::_StartMainLoop (this=0xbfc5a150) at [...]/src/Application.cpp:344
  17. 15 0x0805f2e5 in AO::Application::Start (this=0xbfc5a150) at [...]/src/Application.cpp:89
  18. 16 0x0805b5a9 in main () at [...]/src/main.cpp:34

Comments (1)

  1. Log in to comment