diff --git a/main.cpp b/main.cpp index 2f5f04b..92c7222 100644 --- a/main.cpp +++ b/main.cpp @@ -15,6 +15,7 @@ */ #include +#include #include #include @@ -22,12 +23,11 @@ #include #include -#include -#include -#include +#include void process_xml(std::ostream& os, const std::string& filename) { + // Construct a property tree from the input XML file. boost::property_tree::ptree pt; try { // First, try to read as a binary XML file. @@ -38,8 +38,9 @@ void process_xml(std::ostream& os, const std::string& filename) boost::property_tree::read_xml(filename, pt); } + // Write the ptree to the output. boost::property_tree::xml_writer_settings settings(' ', 2); - write_xml(os, pt, settings); + boost::property_tree::write_xml(os, pt, settings); } int main(int argc, char** argv)