[Libreoffice-commits] online.git: wsd/DocumentBroker.cpp

Tor Lillqvist tml at collabora.com
Wed Dec 21 12:06:32 UTC 2016


 wsd/DocumentBroker.cpp |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

New commits:
commit 07b917f97e9bcfa3fd92fa731d1d95131850fdbc
Author: Tor Lillqvist <tml at collabora.com>
Date:   Wed Dec 21 14:06:07 2016 +0200

    Ignore dummy (epoch) timestamps
    
    Change-Id: I745940005f018c43ff83a48199d7945d5e807a8c

diff --git a/wsd/DocumentBroker.cpp b/wsd/DocumentBroker.cpp
index 515a48e..c9cba49 100644
--- a/wsd/DocumentBroker.cpp
+++ b/wsd/DocumentBroker.cpp
@@ -328,7 +328,9 @@ bool DocumentBroker::load(std::shared_ptr<ClientSession>& session, const std::st
         // Check if document has been modified by some external action
         LOG_DBG("Timestamp now: " << Poco::DateTimeFormatter::format(Poco::DateTime(fileInfo._modifiedTime),
                                                                      Poco::DateTimeFormat::ISO8601_FORMAT));
-        if (_documentLastModifiedTime != fileInfo._modifiedTime)
+        if (_documentLastModifiedTime != Poco::Timestamp::fromEpochTime(0) &&
+            fileInfo._modifiedTime != Poco::Timestamp::fromEpochTime(0) &&
+            _documentLastModifiedTime != fileInfo._modifiedTime)
         {
             LOG_ERR("Document has been modified behind our back, URI [" << uriPublic.toString() << "].");
             // What do do?


More information about the Libreoffice-commits mailing list