summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRalf Habacker <ralf.habacker@freenet.de>2016-09-11 11:13:59 (GMT)
committerRalf Habacker <ralf.habacker@freenet.de>2016-09-11 11:13:59 (GMT)
commitc036a0c04d9c967ba1ad2566eb731a663cc066d3 (patch)
tree7a30c6d5e21a2ddd49dc8d9505a3125a33ba983b
parent3e9f089d6f90085d3e312f3a06d780d9d1c026ff (diff)
Check return value from dynamic_cast against zero in ClassGeneralPage constructor.
CCBUG:368282
-rw-r--r--umbrello/dialogs/pages/classgeneralpage.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/umbrello/dialogs/pages/classgeneralpage.cpp b/umbrello/dialogs/pages/classgeneralpage.cpp
index 8d4e4b1..097a53f 100644
--- a/umbrello/dialogs/pages/classgeneralpage.cpp
+++ b/umbrello/dialogs/pages/classgeneralpage.cpp
@@ -102,7 +102,7 @@ ClassGeneralPage::ClassGeneralPage(UMLDoc* d, QWidget* parent, UMLObject* o)
int row = 2;
UMLClassifier *c = m_pObject->asUMLClassifier();
- if (c->isReference() && c->originType()) {
+ if (c && c->isReference() && c->originType()) {
QLabel *label = new QLabel(i18n("Reference:"), this);
m_pNameLayout->addWidget(label, row, 0);
QLabel *reference = new QLabel(c->originType()->name(), this);