summaryrefslogtreecommitdiff
path: root/src/lib
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2016-07-12 23:32:13 +0100
committerCarl Hetherington <cth@carlh.net>2016-07-12 23:32:13 +0100
commitcf2146fef7540dc5349d7ac3672da0d3bfa971c0 (patch)
tree684845d8a73a1e0e27a28201b45e7594cb0b6421 /src/lib
parent8a7c6c1b3f8c25613019ff074d5b0c266f4e964c (diff)
Stop silently catching exceptions when config load fails.
I'm not sure why this was added, but it could hide serious problems during config load: especially failures to load/create _signer_chain which has been seen in the wild several times.
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/config.cc13
1 files changed, 1 insertions, 12 deletions
diff --git a/src/lib/config.cc b/src/lib/config.cc
index 91966eefb..c483734f8 100644
--- a/src/lib/config.cc
+++ b/src/lib/config.cc
@@ -145,12 +145,10 @@ void
Config::read ()
{
if (!have_existing ("config.xml")) {
- cout << "No existing config.xml; creating chains.\n";
/* Make a new set of signing certificates and key */
_signer_chain = create_certificate_chain ();
/* And similar for decryption of KDMs */
_decryption_chain = create_certificate_chain ();
- cout << "Writing config.\n";
write ();
return;
}
@@ -337,16 +335,7 @@ Config::instance ()
{
if (_instance == 0) {
_instance = new Config;
- try {
- _instance->read ();
- } catch (exception& e) {
- /* configuration load failed; never mind, just
- stick with the default.
- */
- cerr << "dcpomatic: warning: configuration did not load (" << e.what() << "); using defaults\n";
- } catch (...) {
- cerr << "dcpomatic: warning: configuration did not load; using defaults\n";
- }
+ _instance->read ();
}
return _instance;