[Libreoffice-commits] online.git: 2 commits - loolwsd/MasterProcessSession.cpp loolwsd/test loolwsd/TileCache.cpp loolwsd/TileCache.hpp

Tor Lillqvist tml at collabora.com
Tue Apr 19 13:22:43 UTC 2016


 loolwsd/MasterProcessSession.cpp |    4 ++--
 loolwsd/TileCache.cpp            |    4 ++--
 loolwsd/TileCache.hpp            |    2 +-
 loolwsd/test/UnitAdmin.cpp       |    8 ++++----
 4 files changed, 9 insertions(+), 9 deletions(-)

New commits:
commit f825fea9dbc27c44e32a23b9a12255642ec02d14
Author: Tor Lillqvist <tml at collabora.com>
Date:   Tue Apr 19 16:21:55 2016 +0300

    operator '?:' has lower precedence than '+'; '+' will be evaluated first

diff --git a/loolwsd/test/UnitAdmin.cpp b/loolwsd/test/UnitAdmin.cpp
index e4b2bb6..e231775 100644
--- a/loolwsd/test/UnitAdmin.cpp
+++ b/loolwsd/test/UnitAdmin.cpp
@@ -82,7 +82,7 @@ private:
         if (response.getStatus() == HTTPResponse::HTTP_UNAUTHORIZED)
             res = TestResult::TEST_OK;
 
-        Log::info("testIncorrectPassword: " + (res == TestResult::TEST_OK) ? "OK" : "FAIL");
+        Log::info(std::string("testIncorrectPassword: ") + (res == TestResult::TEST_OK ? "OK" : "FAIL"));
         return res;
     }
 
@@ -121,7 +121,7 @@ private:
             res = TestResult::TEST_OK;
         }
 
-        Log::info("testCorrectPassword: " + (res == TestResult::TEST_OK) ? "OK" : "FAIL");
+        Log::info(std::string("testCorrectPassword: ") + (res == TestResult::TEST_OK ? "OK" : "FAIL"));
         return res;
     }
 
@@ -147,7 +147,7 @@ private:
         if (!authorized)
             res = TestResult::TEST_OK;
 
-        Log::info("testWebSocketWithoutCookie: " + (res == TestResult::TEST_OK) ? "OK" : "FAIL");
+        Log::info(std::string("testWebSocketWithoutCookie: ") + (res == TestResult::TEST_OK ? "OK" : "FAIL"));
         return res;
     }
 
@@ -179,7 +179,7 @@ private:
         if (authorized)
             res = TestResult::TEST_OK;
 
-        Log::info("testWebSocketWithCookie: " + (res == TestResult::TEST_OK) ? "OK" : "FAIL");
+        Log::info(std::string("testWebSocketWithCookie: ") + (res == TestResult::TEST_OK ? "OK" : "FAIL"));
         return res;
     }
 
commit bf6dd4e29109474d9ebdc42fc99900023aef4ae0
Author: Tor Lillqvist <tml at collabora.com>
Date:   Tue Apr 19 16:17:58 2016 +0300

    Typo

diff --git a/loolwsd/MasterProcessSession.cpp b/loolwsd/MasterProcessSession.cpp
index ccdc6b0..8e433d1 100644
--- a/loolwsd/MasterProcessSession.cpp
+++ b/loolwsd/MasterProcessSession.cpp
@@ -181,7 +181,7 @@ bool MasterProcessSession::_handleInput(const char *buffer, int length)
 
                 assert(firstLine.size() < static_cast<std::string::size_type>(length));
                 _docBroker->tileCache().saveTile(part, width, height, tilePosX, tilePosY, tileWidth, tileHeight, buffer + firstLine.size() + 1, length - firstLine.size() - 1);
-                auto lock = _docBroker->tileCache().getTilesBeingRenderdLock();
+                auto lock = _docBroker->tileCache().getTilesBeingRenderedLock();
                 std::shared_ptr<TileBeingRendered> tileBeingRendered = _docBroker->tileCache().findTileBeingRendered(part, width, height, tilePosX, tilePosY, tileWidth, tileHeight);
                 if (tileBeingRendered)
                 {
@@ -585,7 +585,7 @@ void MasterProcessSession::sendTile(const char *buffer, int length, StringTokeni
         return;
     }
 
-    auto lock = _docBroker->tileCache().getTilesBeingRenderdLock();
+    auto lock = _docBroker->tileCache().getTilesBeingRenderedLock();
     std::shared_ptr<TileBeingRendered> tileBeingRendered = _docBroker->tileCache().findTileBeingRendered(part, width, height, tilePosX, tilePosY, tileWidth, tileHeight);
     if (tileBeingRendered)
     {
diff --git a/loolwsd/TileCache.cpp b/loolwsd/TileCache.cpp
index 409f316..534cc38 100644
--- a/loolwsd/TileCache.cpp
+++ b/loolwsd/TileCache.cpp
@@ -90,12 +90,12 @@ TileCache::~TileCache()
 {
     Log::info("~TileCache dtor for uri [" + _docURL + "].");
 #if 0
-    auto lock = getTilesBeingRenderdLock();
+    auto lock = getTilesBeingRenderedLock();
     _tilesBeingRendered.clear();
 #endif
 }
 
-std::unique_lock<std::mutex> TileCache::getTilesBeingRenderdLock()
+std::unique_lock<std::mutex> TileCache::getTilesBeingRenderedLock()
 {
     return std::unique_lock<std::mutex>(_tilesBeingRenderedMutex);
 }
diff --git a/loolwsd/TileCache.hpp b/loolwsd/TileCache.hpp
index 54a462e..80c52be 100644
--- a/loolwsd/TileCache.hpp
+++ b/loolwsd/TileCache.hpp
@@ -50,7 +50,7 @@ public:
 
     TileCache(const TileCache&) = delete;
 
-    std::unique_lock<std::mutex> getTilesBeingRenderdLock();
+    std::unique_lock<std::mutex> getTilesBeingRenderedLock();
 
     void rememberTileAsBeingRendered(int part, int width, int height, int tilePosX, int tilePosY, int tileWidth, int tileHeight);
 


More information about the Libreoffice-commits mailing list