summaryrefslogtreecommitdiff
path: root/src/cpl.cc
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2014-02-08 13:30:42 +0000
committerCarl Hetherington <cth@carlh.net>2014-02-08 13:30:42 +0000
commit71de90f74085744d1c5ca35253eec003e41497a2 (patch)
tree637e6c2b6c2fa04da3d64864e0adcef30a0847dd /src/cpl.cc
parent054cc86d5ba734c72780b07a772a55e3a7000a4f (diff)
Fix a couple of errors in Interop XML
Reported-by: Ivan Pullman
Diffstat (limited to 'src/cpl.cc')
-rw-r--r--src/cpl.cc8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/cpl.cc b/src/cpl.cc
index dcb730ff..e333df0d 100644
--- a/src/cpl.cc
+++ b/src/cpl.cc
@@ -243,13 +243,17 @@ CPL::write_xml (bool interop, XMLMetadata const & metadata, shared_ptr<const Sig
}
void
-CPL::write_to_pkl (xmlpp::Node* node) const
+CPL::write_to_pkl (xmlpp::Node* node, bool interop) const
{
xmlpp::Node* asset = node->add_child ("Asset");
asset->add_child("Id")->add_child_text ("urn:uuid:" + _id);
asset->add_child("Hash")->add_child_text (_digest);
asset->add_child("Size")->add_child_text (lexical_cast<string> (_length));
- asset->add_child("Type")->add_child_text ("text/xml");
+ if (interop) {
+ asset->add_child("Type")->add_child_text ("text/xml;asdcpKind=CPL");
+ } else {
+ asset->add_child("Type")->add_child_text ("text/xml");
+ }
}
list<shared_ptr<const Asset> >