loolwsd/LOOLSession.cpp | 2 +- loolwsd/LOOLWSD.hpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
New commits: commit d70280fff8932153677f2caf231f36048ff6071a Author: Henry Castro <hcas...@collabora.com> Date: Fri Dec 18 16:51:08 2015 -0400 loolwsd: when no available child sessions, pre spawns more children diff --git a/loolwsd/LOOLSession.cpp b/loolwsd/LOOLSession.cpp index 513cd5c..f5299aa 100644 --- a/loolwsd/LOOLSession.cpp +++ b/loolwsd/LOOLSession.cpp @@ -688,7 +688,7 @@ void MasterProcessSession::dispatchChild() { LOOLWSD::_namedMutexLOOL.lock(); std::cout << Util::logPrefix() << "No available child sessions, queue new child session" << std::endl; - LOOLWSD::_sharedForkChild.begin()[0] = (LOOLWSD::_sharedForkChild.begin()[0] > 0 ? LOOLWSD::_sharedForkChild.begin()[0] + 1 : 1); + LOOLWSD::_sharedForkChild.begin()[0] = LOOLWSD::_numPreSpawnedChildren; LOOLWSD::_namedMutexLOOL.unlock(); } diff --git a/loolwsd/LOOLWSD.hpp b/loolwsd/LOOLWSD.hpp index 0970fc5..62e4c32 100644 --- a/loolwsd/LOOLWSD.hpp +++ b/loolwsd/LOOLWSD.hpp @@ -32,6 +32,7 @@ public: // statics static int portNumber; static int timeoutCounter; + static int _numPreSpawnedChildren; static bool doTest; static bool volatile isShutDown; static std::string cache; @@ -73,7 +74,6 @@ private: int createComponent(); int createDesktop(); - static int _numPreSpawnedChildren; static std::mutex _rngMutex; #if ENABLE_DEBUG _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits