X-Git-Url: https://git.carlh.net/gitweb/?a=blobdiff_plain;f=src%2Flib%2Fsend_problem_report_job.cc;h=34822b1561d7ade97c41d8dd236a4c383c9888fc;hb=323b8cbb0b95297fbd027ffdc4ea5003b59ef25f;hp=6ab83ee6211d6bea24b93fb6e6367f367d93f979;hpb=da44da6f31f97d39ca91c35955e573e76371f2c2;p=dcpomatic.git diff --git a/src/lib/send_problem_report_job.cc b/src/lib/send_problem_report_job.cc index 6ab83ee62..34822b156 100644 --- a/src/lib/send_problem_report_job.cc +++ b/src/lib/send_problem_report_job.cc @@ -38,7 +38,7 @@ using std::shared_ptr; using std::string; -/** @param film Film thta the problem is with, or 0. +/** @param film Film that the problem is with, or 0. * @param from Email address to use for From: * @param summary Summary of the problem. */ @@ -121,6 +121,10 @@ SendProblemReportJob::add_file (string& body, boost::filesystem::path file) cons { body += file.string() + ":\n"; body += "---<8----\n"; - body += dcp::file_to_string (_film->file(file)); + try { + body += dcp::file_to_string (_film->file(file)); + } catch (...) { + body += "[could not be read]\n"; + } body += "---<8----\n\n"; }