[Libreoffice-commits] online.git: Branch 'distro/collabora/co-4-2' - wsd/Storage.cpp
Mike Kaganski (via logerrit)
logerrit at kemper.freedesktop.org
Tue Jun 30 14:36:38 UTC 2020
wsd/Storage.cpp | 3 +++
1 file changed, 3 insertions(+)
New commits:
commit 12d6c8f95ff4d908b9c612240f7b502125791d77
Author: Mike Kaganski <mike.kaganski at collabora.com>
AuthorDate: Tue Jun 30 16:37:40 2020 +0300
Commit: Michael Meeks <michael.meeks at collabora.com>
CommitDate: Tue Jun 30 16:36:19 2020 +0200
IIS requires content-length for POST requests
Without the content-length, LOCK requests result in 411 response with
the message: "The request must be chunked or have a content length".
Ref: https://forums.iis.net/t/1119456.aspx
Change-Id: Ieceb2bcf478c5f6baf97ee6b89d37622da168df5
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/97524
Tested-by: Jenkins
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice at gmail.com>
Reviewed-by: Mike Kaganski <mike.kaganski at collabora.com>
(cherry picked from commit dd8e852b63598f180d9045214fa7cfc9e90fee24)
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/97500
Reviewed-by: Michael Meeks <michael.meeks at collabora.com>
diff --git a/wsd/Storage.cpp b/wsd/Storage.cpp
index 7e262b1cd..66028aa05 100644
--- a/wsd/Storage.cpp
+++ b/wsd/Storage.cpp
@@ -794,6 +794,9 @@ bool WopiStorage::updateLockState(const Authorization& auth, const std::string&
addStorageReuseCookie(request, cookies);
addWopiProof(request, uriObject, params["access_token"]);
+ // IIS requires content-length for POST requests: see https://forums.iis.net/t/1119456.aspx
+ request.setContentLength(0);
+
psession->sendRequest(request);
Poco::Net::HTTPResponse response;
std::istream& rs = psession->receiveResponse(response);
More information about the Libreoffice-commits
mailing list