ucb/source/ucp/webdav-curl/SerfLockStore.cxx |    5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

New commits:
commit a2decb07a8c4fc63d0b535501e26d82f84dcaf17
Author:     Michael Stahl <michael.st...@allotropia.de>
AuthorDate: Thu Nov 25 18:40:38 2021 +0100
Commit:     Michael Stahl <michael.st...@allotropia.de>
CommitDate: Fri Nov 26 18:03:11 2021 +0100

    ucb: webdav-curl: remove useless assert in getLockTokenForURI()
    
    Change-Id: Ia27acf55bd7baf70c0b57e0922a62b1d9680c5b4
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125848
    Tested-by: Jenkins
    Reviewed-by: Michael Stahl <michael.st...@allotropia.de>
    (cherry picked from commit 9f94ea12c7d919441ccbb8ebc99adff11a2e6fd1)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125887

diff --git a/ucb/source/ucp/webdav-curl/SerfLockStore.cxx 
b/ucb/source/ucp/webdav-curl/SerfLockStore.cxx
index 0de397986f8f..3601d0c66642 100644
--- a/ucb/source/ucp/webdav-curl/SerfLockStore.cxx
+++ b/ucb/source/ucp/webdav-curl/SerfLockStore.cxx
@@ -168,7 +168,10 @@ SerfLockStore::getLockTokenForURI(OUString const& rURI, 
css::ucb::Lock const*con
     {
         return nullptr;
     }
-    assert(it->second.m_Lock.Owner == pLock->Owner); // only own locks expected
+    // Only own locks are expected in the lock store, but depending on the
+    // server it->second.m_Lock.Owner may contain the string this UCP passed in
+    // the LOCK request, or a user identifier generated by the server (happens
+    // with Sharepoint), so just ignore it here.
     // ignore Timeout ?
     return &it->second.m_sToken;
 }

Reply via email to