summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2013-06-02 22:16:17 +0100
committerCarl Hetherington <cth@carlh.net>2013-06-02 22:16:17 +0100
commit52528d511935d95b1a2f0dbf62bcd2af3a6288ad (patch)
tree0723ff67b926428060b0fb11b1546d10fe3de5c7 /src
parentb172ecbede672bdef982e5b45376ac3517440263 (diff)
Tweaks to diffing routines.
Diffstat (limited to 'src')
-rw-r--r--src/cpl.cc6
-rw-r--r--src/types.h2
2 files changed, 6 insertions, 2 deletions
diff --git a/src/cpl.cc b/src/cpl.cc
index e7eb1ced..fd705680 100644
--- a/src/cpl.cc
+++ b/src/cpl.cc
@@ -256,8 +256,10 @@ CPL::write_to_assetmap (xmlpp::Node* node) const
bool
CPL::equals (CPL const & other, EqualityOptions opt, boost::function<void (NoteType, string)> note) const
{
- if (_name != other._name) {
- note (ERROR, "names differ");
+ if (_name != other._name && !opt.cpl_names_can_differ) {
+ stringstream s;
+ s << "names differ: " << _name << " vs " << other._name << "\n";
+ note (ERROR, s.str ());
return false;
}
diff --git a/src/types.h b/src/types.h
index b1de4a0f..edabb9e2 100644
--- a/src/types.h
+++ b/src/types.h
@@ -100,12 +100,14 @@ struct EqualityOptions {
: max_mean_pixel_error (0)
, max_std_dev_pixel_error (0)
, max_audio_sample_error (0)
+ , cpl_names_can_differ (false)
, mxf_names_can_differ (false)
{}
double max_mean_pixel_error;
double max_std_dev_pixel_error;
int max_audio_sample_error;
+ bool cpl_names_can_differ;
bool mxf_names_can_differ;
};