summaryrefslogtreecommitdiff
path: root/src/tools
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2018-03-22 23:32:20 +0000
committerCarl Hetherington <cth@carlh.net>2018-03-22 23:32:20 +0000
commit7bc349aa8da5a046a9e1b0c08e3fc657c380386b (patch)
treefeed7adf004ff3bf469f7c53f3cf56577a4578a3 /src/tools
parent5e1dc8504b047fab5bc7720dbe615326bb95e135 (diff)
Don't crash when trying to create a film in a bad location.
Diffstat (limited to 'src/tools')
-rw-r--r--src/tools/dcpomatic.cc6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/tools/dcpomatic.cc b/src/tools/dcpomatic.cc
index 1e6c49d7b..2285cccff 100644
--- a/src/tools/dcpomatic.cc
+++ b/src/tools/dcpomatic.cc
@@ -427,7 +427,11 @@ private:
int const r = d->ShowModal ();
if (r == wxID_OK && d->check_path() && maybe_save_then_delete_film<FilmChangedClosingDialog>()) {
- new_film (d->path(), d->template_name());
+ try {
+ new_film (d->path(), d->template_name());
+ } catch (boost::filesystem::filesystem_error& e) {
+ error_dialog (this, _("Could not create folder to store film"), std_to_wx(e.what()));
+ }
}
d->Destroy ();