projects
/
dcpomatic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d4422f1
)
Improve error handling in CLI client slightly.
author
Carl Hetherington
<cth@carlh.net>
Fri, 28 Jan 2022 19:06:27 +0000
(20:06 +0100)
committer
Carl Hetherington
<cth@carlh.net>
Wed, 9 Mar 2022 16:04:02 +0000
(17:04 +0100)
src/tools/dcpomatic_cli.cc
patch
|
blob
|
history
diff --git
a/src/tools/dcpomatic_cli.cc
b/src/tools/dcpomatic_cli.cc
index be4d3f51327c53e330675bc2f3d863e8ff9573e2..1293eab0f4ef22523915d7c6d9ef8e4ed06b4be0 100644
(file)
--- a/
src/tools/dcpomatic_cli.cc
+++ b/
src/tools/dcpomatic_cli.cc
@@
-47,6
+47,7
@@
using std::cout;
using std::dynamic_pointer_cast;
using std::list;
using std::pair;
+using std::runtime_error;
using std::setw;
using std::shared_ptr;
using std::string;
@@
-403,7
+404,12
@@
main (int argc, char* argv[])
);
JobManager::instance()->add (job);
} else {
- film->make_dcp (behaviour);
+ try {
+ film->make_dcp (behaviour);
+ } catch (runtime_error& e) {
+ std::cerr << "Could not make DCP: " << e.what() << "\n";
+ exit(EXIT_FAILURE);
+ }
}
bool const error = show_jobs_on_console (progress);