[Libreoffice-commits] online.git: net/Ssl.cpp

Libreoffice Gerrit user logerrit at kemper.freedesktop.org
Mon Dec 3 08:11:41 UTC 2018


 net/Ssl.cpp |   10 +++++++---
 1 file changed, 7 insertions(+), 3 deletions(-)

New commits:
commit 85f24ccb557f16b9542205383bbbe1dfba4ed950
Author:     Miklos Vajna <vmiklos at collabora.com>
AuthorDate: Mon Dec 3 09:10:49 2018 +0100
Commit:     Miklos Vajna <vmiklos at collabora.com>
CommitDate: Mon Dec 3 09:11:22 2018 +0100

    CRYPTO_dynlock_value: make members private
    
    Change-Id: I5328bd272d4aaef1a445b9ddc5dd4c878d803777

diff --git a/net/Ssl.cpp b/net/Ssl.cpp
index 74fd75ada..06c5e06d6 100644
--- a/net/Ssl.cpp
+++ b/net/Ssl.cpp
@@ -22,7 +22,11 @@ extern "C"
     // Not needed in recent (1.x?) versions.
     struct CRYPTO_dynlock_value
     {
-        std::mutex Mutex;
+    public:
+        void lock() { _mutex.lock(); }
+        void unlock() { _mutex.unlock(); }
+    private:
+        std::mutex _mutex;
     };
 }
 
@@ -180,11 +184,11 @@ void SslContext::dynlock(int mode, struct CRYPTO_dynlock_value* lock, const char
 {
     if (mode & CRYPTO_LOCK)
     {
-        lock->Mutex.lock();
+        lock->lock();
     }
     else
     {
-        lock->Mutex.unlock();
+        lock->unlock();
     }
 }
 


More information about the Libreoffice-commits mailing list