The payload of paste can't have length 0.
Now we silently skip such cases, although perhaps we
should be more strict and disconnect the offending
client.
Change-Id: Iaa2e7373277f9e7d85209aec56a2f8ee0ef7e801
Reviewed-on: https://gerrit.libreoffice.org/34112
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
Now it is possible to use:
./loolwsd_fuzzer --config-file=loolwsd.xml --o:storage.filesystem[@allow]=true --o:logging.level=fatal --fuzz=/tmp/looltrace
Ie. no need to specify the LibreOffice install location. Ideally worth
disabling the logging output too, to gain higher performance.
Change-Id: I4fa5f275cd4f4a52fe2cd07e658cea726f6f31c2
We have enabled LOK_FEATURE_NO_TILED_ANNOTATIONS flag already
in Kit.cpp, which means these tests, which assume comments are
rendered as tiles, are no longer relevant, so lets disable them
for now. Surely sometime in future they would completely be
removed and replaced by new tests that assume comments are *not*
rendered in tiles and rather are added/modified/removed by using
comments API. See LOK_CALLBACK_COMMENT for details.
Change-Id: I48b7a0a0aa116d164a3654618ab0e95252d29cf3
This reduces the chance for random test failures.
Change-Id: I961a502d57a3cb4946b3b7febc6e6b03e7f36aa1
Reviewed-on: https://gerrit.libreoffice.org/33858
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
In unittests we need to count the
number of lool processes. This can
take a long time depending on how many
they are and if they are exiting or
new ones being created.
New logic is to reset the timeout
when the numbers are changing until
it settles on either the expected
(when we return), or some other value.
Change-Id: Ia8fcc7ef60586ebec6d8a280174b4dd2eae0ccc4
Reviewed-on: https://gerrit.libreoffice.org/33672
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
Now we don't get a situation where there would be a tremendous amount of
invalidates & tile render requests piled in the queue, so we can do it
deterministic again.
The only thing that could potentially pile in the queue are the keypresses
events sent from the clients, but that is a different problem anyway.
This reverts commit c326228774.
Change-Id: I98e199eab0187bf5f47ce322ac1b1b2e3b976b85
Which is not odd, as it seems to be a forkit process that tries to load
unit-oob.so, and the symbol in question,
UnitWSD::testHandleRequest(UnitWSD::TestRequest,
UnitHTTPServerRequest&, UnitHTTPServerResponse&), is in LOOWSD.cpp.
Oh well. Whatever.
Change-Id: I0e0409b7247acdcd00e830d6fa63e73f27ea6c3a
The server tells the client the hash of each tile it sends (calculated
from the contents of the tile, not its PNG encoding). When the client
asks for a tile to be refreshed, it tells the server what the hash of
the existing tile is. If the server notices that the tile contents
hasn't actually changed, it doesn't PNG encode it and doesn't send it
to the client.
The intent is that this will reduce load on the server and also avoid
unnecessary tile traffic.
Change-Id: Ia06ca68655ea984ed4319f24f4470afda322eccf
If we are logging a message, we want to see the first line of it in
its entirety if possible. Especially now with more parameters being
added to tile messages, 120 was not enough to see the added
interesting ones.
Bin the silly test that used knowledge of what the limit is. We should
not test a coindidental arbitrary number that is not a documented part
of an API. If we want to test the default abbreviation functionality,
we need to at least make that default limit (now 500) public in
Protocol.hpp.
Change-Id: Iea59ba46e8331e2a839c792146f123fed9df2b82
When there are many views requesting tiles,
disconnecting any should not cancel tiles
for other views.
Change-Id: I6029432c4b9ab931811dcb3b03b0441b413a9971
Reviewed-on: https://gerrit.libreoffice.org/32872
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
Since the Impress slides use large fonts, we end up
overflowing the part bounds with this test.
Luckily the top row of text has smaller font, and
more vertical space within the slide, so now
we edit the top-left textbox and this test
doesn't fail anymore (tested 50 times) when
it failed ~1 in 4 previously.
Change-Id: I13d8cc4462d48b128578a9d3fdde90a79c607c4b
Reviewed-on: https://gerrit.libreoffice.org/32862
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
This makes debugging much easier as one can
readily match WSD logs with a given test.
Change-Id: I8f2c83d67189038699af3f24dee205bc7efb5c28
Reviewed-on: https://gerrit.libreoffice.org/32860
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
Previously tilecombine had its own version, which is
nonesensical, since it's not really a tile.
Now it passes the version to the tiles when
parsing and serializes version per-tile.
Change-Id: I5db8d94880431e3d2a40b6787c6fe51a05771305
Reviewed-on: https://gerrit.libreoffice.org/32633
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
As far as I see, we tend to use the same namespace name as the
basename of the corresponding include file, and this stuff is defined
in a file called Png.hpp.
Change-Id: Id859e13e94568abd9f1d5b4ef3bfbbb0c156db11
canceltiles is not guaranteed to prevent
tiles from getting sent back to the client.
There is an obvious race between receiving
tile requets and cancelling them.
This reduces failures by repeating the
unittest when there is spurious failure.
Change-Id: Icf299e2212e175dc4c0cbc1d2f91c37725f2b261
Reviewed-on: https://gerrit.libreoffice.org/32631
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>