[Uml-devel] [Bug 122188] New: crash when creating a datatype with the same name as a class

Yan Morin yansanmo at iquebec.com
Fri Feb 17 15:59:02 UTC 2006


------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
         
http://bugs.kde.org/show_bug.cgi?id=122188         
           Summary: crash when creating a datatype with the same name as a
                    class
           Product: umbrello
           Version: unspecified
          Platform: Compiled Sources
        OS/Version: Linux
            Status: UNCONFIRMED
          Severity: crash
          Priority: NOR
         Component: general
        AssignedTo: umbrello-devel.kde.org
        ReportedBy: yansanmo iquebec com


Version:           1.5.2 (using KDE KDE 3.5.1)
Installed from:    Compiled From Sources

How to reproduce
1. Create a class with the name "test"
2. Create a datatype with the name "test"
3. The user see the popup: 
"The name you entered was not unique! Creation process has been canceled." 

4. Click on OK
5. Crash...

it's because UMLListViewItem::okRename is call, then call the UMLListView to remove itself (this). Then it crash because this is not valid anymore.
in umllistviewitem.cpp
    332 void UMLListViewItem::okRename( int col ) {
    339         if ( s_pListView->slotItemRenamed( this, col ) ) {

in umllistview.cpp   
2234 bool UMLListView::slotItemRenamed( QListViewItem * item , int /*col*/ ) {
2274             delete item;

It's also happen when you create a Datatype or a class, then erase the name and press "enter".




More information about the umbrello-devel mailing list