X-Git-Url: https://main.carlh.net/gitweb/?a=blobdiff_plain;f=src%2Flib%2Ftypes.cc;h=9519b309729db5ed323ccdd7bcd8ef0ad93a9d1d;hb=8902a7adb63e2dac24e877ed1035bf344397c260;hp=19e5da6ec78aa8c39c099f06d47f206cb3ab746d;hpb=2596b1db2fff8a9cc56be97099442dc791692882;p=dcpomatic.git diff --git a/src/lib/types.cc b/src/lib/types.cc index 19e5da6ec..9519b3097 100644 --- a/src/lib/types.cc +++ b/src/lib/types.cc @@ -35,6 +35,7 @@ using std::max; using std::min; using std::string; +using std::list; using boost::shared_ptr; using dcp::raw_convert; @@ -193,7 +194,11 @@ CPLSummary::CPLSummary (boost::filesystem::path p) : dcp_directory (p.leaf().string()) { dcp::DCP dcp (p); - dcp.read (); + list notes; + dcp.read (¬es); + if (!notes.empty()) { + throw dcp::ReadError(dcp::note_to_string(notes.front())); + } cpl_id = dcp.cpls().front()->id(); cpl_annotation_text = dcp.cpls().front()->annotation_text();