[Libreoffice-commits] online.git: Branch 'distro/collabora/collabora-online-1-9' - 2 commits - loolwsd/IoUtil.cpp
Pranav Kant
pranavk at collabora.co.uk
Thu Sep 1 19:40:05 UTC 2016
loolwsd/IoUtil.cpp | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
New commits:
commit 8f54c13edd084a46ad5130618fabae03d2f67e15
Author: Pranav Kant <pranavk at collabora.co.uk>
Date: Fri Sep 2 00:41:41 2016 +0530
loolwsd: Fix build
Change-Id: If55ad5dfe3f16c9cf4d15d57d199c392d8814e24
diff --git a/loolwsd/IoUtil.cpp b/loolwsd/IoUtil.cpp
index 8077cab..1e5db62 100644
--- a/loolwsd/IoUtil.cpp
+++ b/loolwsd/IoUtil.cpp
@@ -100,7 +100,7 @@ void SocketProcessor(const std::shared_ptr<WebSocket>& ws,
{
n = receiveFrame(*ws, payload.data(), payload.capacity(), flags);
}
- catch (const TimeoutException &)
+ catch (const Poco::TimeoutException&)
{
Log::debug("SocketProcessor: Spurious TimeoutException, ignored");
continue;
commit 4e7b6e31e462c2997d6ee1adad201f2e65299fff
Author: Tor Lillqvist <tml at collabora.com>
Date: Thu Sep 1 19:44:51 2016 +0300
Ignore unexpected TimeoutException from receiveFrame() in SocketProcessor()
Seems to get rid of some (maybe all) "unexpected connection error"
issues for me at least.
diff --git a/loolwsd/IoUtil.cpp b/loolwsd/IoUtil.cpp
index 868b4ba..8077cab 100644
--- a/loolwsd/IoUtil.cpp
+++ b/loolwsd/IoUtil.cpp
@@ -96,7 +96,15 @@ void SocketProcessor(const std::shared_ptr<WebSocket>& ws,
}
payload.resize(payload.capacity());
- n = receiveFrame(*ws, payload.data(), payload.capacity(), flags);
+ try
+ {
+ n = receiveFrame(*ws, payload.data(), payload.capacity(), flags);
+ }
+ catch (const TimeoutException &)
+ {
+ Log::debug("SocketProcessor: Spurious TimeoutException, ignored");
+ continue;
+ }
payload.resize(n > 0 ? n : 0);
if (n <= 0 || ((flags & WebSocket::FRAME_OP_BITMASK) == WebSocket::FRAME_OP_CLOSE))
More information about the Libreoffice-commits
mailing list