wsd/LOOLWSD.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-)
New commits: commit 79c1791764224c8c09c7a9fd4bec306605108701 Author: Ashod Nakashian <ashod.nakash...@collabora.co.uk> Date: Sat Feb 11 11:36:38 2017 -0500 wsd: don't block on autosave Change-Id: Id87465f0aeea9d4f29caea9c88d3a8c7837d8ec2 Reviewed-on: https://gerrit.libreoffice.org/34191 Reviewed-by: Ashod Nakashian <ashnak...@gmail.com> Tested-by: Ashod Nakashian <ashnak...@gmail.com> diff --git a/wsd/LOOLWSD.cpp b/wsd/LOOLWSD.cpp index 97a6088..d268d68 100644 --- a/wsd/LOOLWSD.cpp +++ b/wsd/LOOLWSD.cpp @@ -2518,8 +2518,11 @@ int LOOLWSD::main(const std::vector<std::string>& /*args*/) cleanupDocBrokers(); for (auto& pair : DocBrokers) { - auto docLock = pair.second->getLock(); - pair.second->autoSave(false, 0, docLock); + auto docLock = pair.second->getDeferredLock(); + if (docLock.try_lock()) + { + pair.second->autoSave(false, 0, docLock); + } } } catch (const std::exception& exc) _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits