GNOME Bugzilla – Bug 326453
Crash on UML Class properties page
Last modified: 2006-01-14 13:56:39 UTC
Steps to reproduce: 1. Open a dia file with UML class objects, or create a new one and add an UML class. 2. Add some attributes. 3. Add/modify some operations. 4. Apply it Stack trace: Program received signal SIGSEGV, Segmentation fault.
+ Trace 65097
Thread 46912544556544 (LWP 668)
Other information: Seems to me that attributes_read_from_dialog() in class_dialog.c calls umlclass_sanity_check() while the connection point array is not finalized yet. If I comment it out (line 823 in class_dialog.c, the last statement in attributes_read_from_dialog()) everything works fine. The function umlclass_apply_props_from_dialog() which calls attributes_read_from_dialog() does the sanity check also, and finalizes the array by calling operations_read_from_dialog() right after attributes_read_from_dialog(). Is it really enough to get rid of that umlclass_sanity_check() call?
To fix this bug, yes. The whole thing involved some more changes: 2006-01-14 Hans Breuer <hans@breuer.org> * lib/debug.c : replace wrong call to vprintf() - missing file descriptor - with the more appropriate g_vprintf(). Thus dia_assert_true() does not smash the stack anymore on win32. * objects/UML/class.c objects/UML/class_dialog.c objects/UML/uml.h objects/UML/umlattribute.c objects/UML/umloperation.c : reverted the memory managment of UMLAttribute/UMLOperation's ConnectionPoint(s) back to how it was up until 0.94. This finally makes the UMLClass work again including undo/redo support. Fixes bug #314153 and en passant bug #326453.