Setup MXF keys after re-load before generating KDM; allow numbers in KDM names.
authorCarl Hetherington <cth@carlh.net>
Tue, 24 Sep 2013 22:23:52 +0000 (23:23 +0100)
committerCarl Hetherington <cth@carlh.net>
Tue, 24 Sep 2013 22:23:52 +0000 (23:23 +0100)
src/lib/film.cc
src/lib/util.cc

index 069be9b98b533224fae271b6934615a3b66d9cfc..d218524f467c8828e51c6dbe79339a3b571a98f3 100644 (file)
@@ -961,6 +961,8 @@ Film::make_kdms (
                time_t now = time (0);
                struct tm* tm = localtime (&now);
                string const issue_date = libdcp::tm_to_string (tm);
+
+               dcp.cpls().front()->set_mxf_keys (key ());
                
                libdcp::KDM kdm (
                        dcp.cpls().front(), signer, (*i)->certificate, from, until, "DCP-o-matic", issue_date
index 667ee8ce95926f8c10bf24db3c71d2a41fa77b76..baa37ae7c4da838027ba6d152cc5383460185146 100644 (file)
@@ -807,7 +807,7 @@ tidy_for_filename (string f)
 {
        string t;
        for (size_t i = 0; i < f.length(); ++i) {
-               if (isalpha (f[i]) || f[i] == '_' || f[i] == '-') {
+               if (isalnum (f[i]) || f[i] == '_' || f[i] == '-') {
                        t += f[i];
                } else {
                        t += '_';