[Libreoffice-commits] online.git: 2 commits - loolwsd/LOOLKit.cpp

Tor Lillqvist tml at collabora.com
Fri Apr 8 14:17:44 UTC 2016


 loolwsd/LOOLKit.cpp |    7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

New commits:
commit d0309d9a834190f6f32d35aeb1deb2ff3edc4579
Author: Tor Lillqvist <tml at collabora.com>
Date:   Fri Apr 8 17:11:36 2016 +0300

    No reason to use unsigned instead of bool

diff --git a/loolwsd/LOOLKit.cpp b/loolwsd/LOOLKit.cpp
index ba32b81..4591300 100644
--- a/loolwsd/LOOLKit.cpp
+++ b/loolwsd/LOOLKit.cpp
@@ -364,9 +364,9 @@ private:
     Thread _thread;
     std::shared_ptr<ChildProcessSession> _session;
     std::shared_ptr<WebSocket> _ws;
-    std::atomic<unsigned> _stop;
+    std::atomic<bool> _stop;
     std::mutex _threadMutex;
-    std::atomic<unsigned> _joined;
+    std::atomic<bool> _joined;
 };
 
 /// A document container.
commit 40914ca336e0ca7709f3496a01870133e0df604f
Author: Tor Lillqvist <tml at collabora.com>
Date:   Fri Apr 8 17:06:51 2016 +0300

    Initialise the Connection::_joined in the constructor
    
    This seems to get rid of the "terminate called after throwing an
    instance of 'Poco::SystemException'" problem for me at least.
    
    Sigh. Why can't the compiler warn about such things? I build with
    clang++ -Wall -Wextra. The Connection class is fully defined inside
    the LOOLKit.cpp so it should be able to, right?

diff --git a/loolwsd/LOOLKit.cpp b/loolwsd/LOOLKit.cpp
index aaea71f..ba32b81 100644
--- a/loolwsd/LOOLKit.cpp
+++ b/loolwsd/LOOLKit.cpp
@@ -223,7 +223,8 @@ public:
                std::shared_ptr<WebSocket> ws) :
         _session(session),
         _ws(ws),
-        _stop(false)
+        _stop(false),
+        _joined(false)
     {
         Log::info("Connection ctor in child for " + _session->getId());
     }


More information about the Libreoffice-commits mailing list