Cleanup: extract verify_assetmap().
authorCarl Hetherington <cth@carlh.net>
Sun, 1 Jan 2023 19:57:45 +0000 (20:57 +0100)
committerCarl Hetherington <cth@carlh.net>
Sat, 7 Jan 2023 21:45:21 +0000 (22:45 +0100)
src/verify.cc

index a797813a526adb0736e1e03c3f0d44fdbfb8a245..b554612b1480641f2bb1cce07df9f1889b4f4e93 100644 (file)
@@ -1637,6 +1637,19 @@ verify_pkl(
 }
 
 
+
+static
+void
+verify_assetmap(
+       shared_ptr<const DCP> dcp,
+       boost::filesystem::path xsd_dtd_directory,
+       vector<VerificationNote>& notes
+       )
+{
+       validate_xml(dcp->asset_map_path().get(), xsd_dtd_directory, notes);
+}
+
+
 vector<VerificationNote>
 dcp::verify (
        vector<boost::filesystem::path> directories,
@@ -1703,7 +1716,7 @@ dcp::verify (
 
                if (dcp->asset_map_path()) {
                        stage ("Checking ASSETMAP", dcp->asset_map_path().get());
-                       validate_xml (dcp->asset_map_path().get(), *xsd_dtd_directory, notes);
+                       verify_assetmap(dcp, *xsd_dtd_directory, notes);
                } else {
                        notes.push_back ({VerificationNote::Type::ERROR, VerificationNote::Code::MISSING_ASSETMAP});
                }