[Libreoffice-commits] online.git: loleaflet/js wsd/LOOLWSD.cpp
Michael Meeks (via logerrit)
logerrit at kemper.freedesktop.org
Fri Apr 24 18:57:38 UTC 2020
loleaflet/js/global.js | 2 +-
wsd/LOOLWSD.cpp | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
New commits:
commit 5c4981794f33b15ed313554590b4fa9a05b0ffcc
Author: Michael Meeks <michael.meeks at collabora.com>
AuthorDate: Sat Apr 18 21:24:41 2020 +0100
Commit: Jan Holesovsky <kendy at collabora.com>
CommitDate: Fri Apr 24 20:57:19 2020 +0200
Proxy: adapt the path with a serial for each request.
Helps to debug, and avoids the webserver getting unhappy.
Change-Id: I632550f2ad26eef973cd036422f9f1a73d0f0764
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/92817
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice at gmail.com>
Reviewed-by: Jan Holesovsky <kendy at collabora.com>
diff --git a/loleaflet/js/global.js b/loleaflet/js/global.js
index 640da1e3f..1e09a86e0 100644
--- a/loleaflet/js/global.js
+++ b/loleaflet/js/global.js
@@ -334,7 +334,7 @@
};
this.getEndPoint = function(type) {
var base = this.uri;
- return base.replace(/^ws/, 'http') + '/' + type;
+ return base.replace(/^ws/, 'http') + '/' + type + '/' + this.outSerial;
};
console.debug('proxy: new socket ' + this.id + ' ' + this.uri);
diff --git a/wsd/LOOLWSD.cpp b/wsd/LOOLWSD.cpp
index ba1d83c77..38496b184 100644
--- a/wsd/LOOLWSD.cpp
+++ b/wsd/LOOLWSD.cpp
@@ -2343,8 +2343,8 @@ private:
// Util::dumpHex(std::cerr, "clipboard:\n", "", socket->getInBuffer()); // lots of data ...
handleClipboardRequest(request, message, disposition, socket);
}
- else if (request.has("ProxyPrefix") && reqPathTokens.count() > 2 &&
- (reqPathTokens[reqPathTokens.count()-2] == "ws"))
+ else if (request.has("ProxyPrefix") && reqPathTokens.count() > 3 &&
+ (reqPathTokens[reqPathTokens.count()-3] == "ws"))
{
std::string decodedUri; // WOPISrc
Poco::URI::decode(reqPathTokens[1], decodedUri);
More information about the Libreoffice-commits
mailing list