wsd/LOOLWSD.hpp | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-)
New commits: commit d876290762ee7af989b08c60a5ed9aa3c5a68f96 Author: Aron Budea <aron.bu...@collabora.com> AuthorDate: Tue Sep 8 14:06:47 2020 +0200 Commit: Michael Meeks <michael.me...@collabora.com> CommitDate: Wed Sep 9 08:55:55 2020 +0200 wsd: Don't fail if config item is missing in loolwsd.xml After upgrading from old versions that didn't include config.storage.ssl in loolwsd.xml, an exception was thrown and not caught, and loolwsd failed to start with the following message: "Not found: storage.ssl.cert_file_path". Change-Id: Id0ca76632c513c6f5c80797a2c7d20f0173e4b56 Reviewed-on: https://gerrit.libreoffice.org/c/online/+/102250 Tested-by: Jenkins Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoff...@gmail.com> Reviewed-by: Michael Meeks <michael.me...@collabora.com> diff --git a/wsd/LOOLWSD.hpp b/wsd/LOOLWSD.hpp index 533c4dfd0..7f1e05a27 100644 --- a/wsd/LOOLWSD.hpp +++ b/wsd/LOOLWSD.hpp @@ -351,7 +351,15 @@ public: static std::string getPathFromConfigWithFallback(const std::string& name, const std::string& fallbackName) { - std::string value = LOOLWSD::getPathFromConfig(name); + std::string value; + // the expected path might not exist, in which case Poco throws an exception + try + { + value = LOOLWSD::getPathFromConfig(name); + } + catch (...) + { + } if (value.empty()) return LOOLWSD::getPathFromConfig(fallbackName); return value; _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits