[umbrello-devel] [umbrello] [Bug 341709] Crash while importing C++ code from existing project
Ralf Habacker
ralf.habacker at freenet.de
Fri Dec 12 09:28:16 UTC 2014
https://bugs.kde.org/show_bug.cgi?id=341709
--- Comment #17 from Ralf Habacker <ralf.habacker at freenet.de> ---
(In reply to Ralf Habacker from comment #16)
> (In reply to Oliver Kellogg from comment #13)
> > (In reply to Ralf Habacker from comment #11)
> 1. shows that an UMLAssociation instance is a parent of an UML Classifier
> - package class name is 'testing'
> - the parent is a dependency with
> - Role A - class "ConstraintPackage"
> - Role B - class "ConstraintPackageField"
>
The related code is in reachability/test_util.h
25: class TestNetwork : public ::testing::Test {
in import_utils.cpp::createUMLObject() line 237 there is called:
if (components.count() > 1) {
typeName = components.back();
components.pop_back();
while (components.count()) {
QString scopeName = components.front();
components.pop_front();
o = umldoc->findUMLObject(scopeName,
UMLObject::ot_UMLObject, parentPkg);
o returns an UMLAssociation instance named 'testing'
if (o) {
parentPkg = static_cast<UMLPackage*>(o);
which is casted to an UMLPackage and sets parentPkg not to zero.
It looks wrong to accept an association as class parent, but the root cause is
that dynamic_cast fails to cast an UMLAssociation instance to UMLPackage* to
zero.
BTW: I compiled umbrello on opensuse 13.1 x86_64 with gcc 4.8.1
--
You are receiving this mail because:
You are the assignee for the bug.
Make the world a better place. Donate to our year end fundraiser https://www.kde.org/fundraisers/yearend2014/
More information about the umbrello-devel
mailing list