summaryrefslogtreecommitdiff
path: root/src/xmlparser.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/xmlparser.cc')
-rw-r--r--src/xmlparser.cc8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/xmlparser.cc b/src/xmlparser.cc
index a362f95..03a54a1 100644
--- a/src/xmlparser.cc
+++ b/src/xmlparser.cc
@@ -64,6 +64,10 @@ void XmlParser::startTag(std::string name, attributes_t &attr)
parents.push(node->id);
}
+ if(name == "attribute") {
+ attr_name = attr["name"];
+ }
+
cdata = "";
}
@@ -76,7 +80,7 @@ void XmlParser::endTag(std::string name)
parents.pop();
}
- if(name == "title") {
- node->data.title = cdata;
+ if(name == "attribute") {
+ node->data.attributes[attr_name] = cdata;
}
}