summaryrefslogtreecommitdiffstats
path: root/src/Data/Info.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/Data/Info.cpp')
-rw-r--r--src/Data/Info.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/Data/Info.cpp b/src/Data/Info.cpp
index 28b85db..f0ce024 100644
--- a/src/Data/Info.cpp
+++ b/src/Data/Info.cpp
@@ -24,10 +24,12 @@ namespace Data {
Info::Info(xmlpp::Element *node) {
nameNode = dynamic_cast<xmlpp::Element*>(node->get_children("name").front());
- name = nameNode->get_child_text()->get_content();
+ if(nameNode->has_child_text())
+ name = nameNode->get_child_text()->get_content();
descNode = dynamic_cast<xmlpp::Element*>(node->get_children("desc").front());
- desc = descNode->get_child_text()->get_content();
+ if(descNode->has_child_text())
+ desc = descNode->get_child_text()->get_content();
}
}