summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAshod Nakashian <ashod.nakashian@collabora.co.uk>2020-01-08 03:37:47 -0500
committerMichael Meeks <michael.meeks@collabora.com>2020-01-14 13:01:05 +0100
commit4619ac73ffb31ce7f3bb30accb5a5be116529bff (patch)
tree7695c231f141689a902f2feaa9b0600274337cf4
parent7254183877a211f6926b46a6793200da19224af0 (diff)
wsd: minor cleanup
Change-Id: I2c062e1f7d309c8d1c54e6d0e8ca4c40f288d09d Reviewed-on: https://gerrit.libreoffice.org/c/online/+/86723 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
-rw-r--r--kit/Kit.cpp17
1 files changed, 6 insertions, 11 deletions
diff --git a/kit/Kit.cpp b/kit/Kit.cpp
index a8855f1c3..78eea14eb 100644
--- a/kit/Kit.cpp
+++ b/kit/Kit.cpp
@@ -1854,27 +1854,22 @@ private:
}
public:
- bool hasQueued()
- {
- return !_tileQueue->isEmpty();
- }
-
void drainQueue(const std::chrono::steady_clock::time_point &now)
{
try
{
- while (hasQueued())
+ while (!_tileQueue->isEmpty())
{
- const TileQueue::Payload input = _tileQueue->pop();
-
- LOG_TRC("Kit Recv " << LOOLProtocol::getAbbreviatedMessage(input));
-
if (_stop || SigUtil::getTerminationFlag())
{
- LOG_INF("_stop or TerminationFlag is set, breaking out of loop");
+ LOG_INF("_stop or TerminationFlag is set, breaking Document::drainQueue of loop");
break;
}
+ const TileQueue::Payload input = _tileQueue->pop();
+
+ LOG_TRC("Kit Recv " << LOOLProtocol::getAbbreviatedMessage(input));
+
const std::vector<std::string> tokens = LOOLProtocol::tokenize(input.data(), input.size());
if (tokens[0] == "eof")