wsd/LOOLWSD.hpp | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-)
New commits: commit 12558cd70f08a59c81d5cd371cb49d13c049329c Author: Aron Budea <aron.bu...@collabora.com> AuthorDate: Tue Sep 8 14:06:47 2020 +0200 Commit: Andras Timar <andras.ti...@collabora.com> CommitDate: Wed Sep 9 14:19:43 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> (cherry picked from commit d876290762ee7af989b08c60a5ed9aa3c5a68f96) Reviewed-on: https://gerrit.libreoffice.org/c/online/+/102296 Reviewed-by: Andras Timar <andras.ti...@collabora.com> diff --git a/wsd/LOOLWSD.hpp b/wsd/LOOLWSD.hpp index 8d9653cd5..5c9c4012a 100644 --- a/wsd/LOOLWSD.hpp +++ b/wsd/LOOLWSD.hpp @@ -333,7 +333,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