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

Pranav Kant pranavk at collabora.co.uk
Mon Feb 15 00:31:47 UTC 2016


 loolwsd/LOOLKit.cpp |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 93fdcb34c48c0a877c76175892e85b32e97cfccf
Author: Pranav Kant <pranavk at collabora.co.uk>
Date:   Sun Feb 7 14:48:32 2016 +0530

    loolwsd: Do not unload without a successfull load
    
    A load document operation may fail, for example, when user enters
    a wrong password or no password. In such cases ToPrisoner sends a
    disconnect to child. Child do not need to take any steps in this
    case, such as, decrementing the view counter, because nothing was
    loaded.
    
    Change-Id: Ib71f871aa1728c6355563362987800dece1679d3
    Reviewed-on: https://gerrit.libreoffice.org/22203
    Reviewed-by: Ashod Nakashian <ashnakash at gmail.com>
    Tested-by: Ashod Nakashian <ashnakash at gmail.com>

diff --git a/loolwsd/LOOLKit.cpp b/loolwsd/LOOLKit.cpp
index 2b47a0b..80a763b 100644
--- a/loolwsd/LOOLKit.cpp
+++ b/loolwsd/LOOLKit.cpp
@@ -558,7 +558,7 @@ private:
 
         const unsigned intSessionId = Util::decodeId(sessionId);
         const auto it = _connections.find(intSessionId);
-        if (it == _connections.end() || !it->second)
+        if (it == _connections.end() || !it->second || !_loKitDocument)
         {
             // Nothing to do.
             return;


More information about the Libreoffice-commits mailing list