[Uml-devel] KDE/kdesdk/umbrello/umbrello

Ralf Habacker ralf.habacker at gmail.com
Sat Dec 17 22:19:59 UTC 2011


SVN commit 1268979 by habacker:

sporadic crash fix when calling item->getID() caused by free'd item->m_object

 M  +4 -2      umllistview.cpp  


--- trunk/KDE/kdesdk/umbrello/umbrello/umllistview.cpp #1268978:1268979
@@ -333,9 +333,11 @@
             UMLListViewItem *current = static_cast<UMLListViewItem*>(currentItem());
             UMLListViewItem *item = static_cast<UMLListViewItem*>((k == Qt::Key_Down) ? itemBelow(current) : itemAbove(current));
             if (item) {
+                Uml::IDType id = item->getID();
+                UMLObject *o = item->umlObject();
                 setCurrentItem(item);
-                m_doc->changeCurrentView(item->getID());
-                UMLApp::app()->docWindow()->showDocumentation(item->umlObject(), false);
+                m_doc->changeCurrentView(id);
+                UMLApp::app()->docWindow()->showDocumentation(o, false);
             }
         }
         else {




More information about the umbrello-devel mailing list