From fa2c49210c9fcf0f26205927aec0aceb13ca69ce Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Mon, 9 Jul 2018 20:10:09 +0100 Subject: Don't write multiple tags to Interop subtitles (#1273). --- test/srt_subtitle_test.cc | 22 +++------------------- 1 file changed, 3 insertions(+), 19 deletions(-) (limited to 'test/srt_subtitle_test.cc') diff --git a/test/srt_subtitle_test.cc b/test/srt_subtitle_test.cc index a601ea58a..6c2928fa8 100644 --- a/test/srt_subtitle_test.cc +++ b/test/srt_subtitle_test.cc @@ -89,25 +89,9 @@ static void check_subtitle_file (shared_ptr film, boost::filesystem::path ref) { /* Find the subtitle file and check it */ - for ( - boost::filesystem::directory_iterator i = boost::filesystem::directory_iterator (film->directory().get() / film->dcp_name (false)); - i != boost::filesystem::directory_iterator (); - ++i) { - - if (boost::filesystem::is_directory (i->path ())) { - for ( - boost::filesystem::directory_iterator j = boost::filesystem::directory_iterator (i->path ()); - j != boost::filesystem::directory_iterator (); - ++j) { - - if (boost::algorithm::starts_with (j->path().leaf().string(), "sub_")) { - list ignore; - ignore.push_back ("SubtitleID"); - check_xml (*j, ref, ignore); - } - } - } - } + list ignore; + ignore.push_back ("SubtitleID"); + check_xml (subtitle_file(film), ref, ignore); } /** Make another DCP with a longer .srt file */ -- cgit v1.2.3