Removed all uses of KIT_IN_PROCESS, used Utils::isKitInProcess()
when necessary. Also removed the now unused parameter 'limit' from
forkLibreOfficeKit.
Signed-off-by: Jaume Pujantell <jaume.pujantell@collabora.com>
Change-Id: I068d3f55ab49076590f111847c87b3188f4d25d0
Added code that spawns forkit and lokit in threads instead of new processes.
Signed-off-by: Jaume Pujantell <jaume.pujantell@collabora.com>
Change-Id: I6b6ad6dccfedaf28ebd0d68851205c540b9a0317
Extract some functions from ForKit.cpp and COOLWSD.cpp to new files
so we can do a kit in process mode without using ifdef directives.
Signed-off-by: Jaume Pujantell <jaume.pujantell@collabora.com>
Change-Id: I7529f8f46a8026318244666b27d1ce72ed5ad4ca
debugging some intermittent failures in UnitBadDocLoad I see that there
are some duplicate jsdialog messages appearing which is easily
reproducible by just opening test/data/corrupted.odt in online.
probably has been like this since:
commit 7f70197723
Date: Mon Dec 28 11:37:27 2020 -0400
kit: enable input process when early dialog show
and possibly not the problem I was originally trying to chase
Signed-off-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Change-Id: I7aa342e86ad9ae73082cb71f1b2c9b2bf0f212b9
Also use some allowed path for HOME and XDG_CONFIG_HOME so we start correctly.
Setup Work path for pdf/epub export.
Enable osl allowed paths for nocap only.
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: I4fa058fe5fabc5eafdff7630dfcc72dedfe22e4a
Also move the nocaps TMPDIR into the jail folder, to sandbox better.
Change-Id: I161695b4585a2c6003779caa88152b744d36266b
Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
Avoids a number of compile time conditionals and adds flexibility.
Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
Change-Id: Iff6b294b504526e70715e436ad33d47c8df4752c
Avoid screen reader to wrongly report text when a shape or image is
selected:
- Got editable area to be made empty when user is not editing text
- Got default for any input to be prevented (except for some special
cases) when user is not editing text so editable area is kept empty
The selection action and the selected object name (e.g. "Rectangle",
"Presentation Title", etc.) are sent to the client.
That allows screen reader to report: "Presentation Title selected" or
"Rectangle unselected", according to the action type.
Selection text content is reported too when available.
Something alike is reported on cell navigation in a spreadsheet.
Signed-off-by: Marco Cecchetti <marco.cecchetti@collabora.com>
Change-Id: I75a8b66ef8cb7b24b28d749f0b24afe2587de45e
This removes the unused requestloksession command
and all references to it, including protocol documentation.
Signed-off-by: Areg Nakashian <ss4crifice@gmail.com>
Change-Id: I8c410460a5f500f724996fbcbf8f9650028daaf9
It seems large groups of people don't have a use for overwrite mode
- Would like to avoid enable it by default
This is just the first step on improving the user experience here.
------
The whole plan would be to:
- 1st Follow up PR
- Where we disable the overwrite mode when enableExperimental is true
this we will be able to see if community likes that change or not before making it everywhere
- Other possible improvements
- Triger a snackbar for the first time the user press the Insert key
- If the feature is disabled we would show snackbar with timeout
"Overwrite is disabled. Please contact admin."[Dismiss]
- If the feature is enabled we would show snackbar with timeout
"Overwrite mode is now enabled" [Disable] (Disable here means the same action as pressing again the **Insert** does)
Signed-off-by: Gülşah Köse <gulsah.kose@collabora.com>
Change-Id: I060b3d2d9d1e7e29a18f5ea1d619c9349eae67c3
Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
AdminModel::cleanupResourceConsumingDocs uses SIGABRT as first
attept to kill misbehaving documents, we should give
DocumentBroker a chance to quarantine documents killed off by
SIGABRT as we do SIGSEGV/SIGBUS
Signed-off-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Change-Id: Ic3a703572393050379b5a1444a5380bbeafcf2d3
in which case don't send it, which then implies we might have
an empty shareFDs which we can treat the same as a nonexisting
shareFDs
Signed-off-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Change-Id: I80a78a01c69dbee5ee28a64442a5069a6c2b4dbe
On iOS, each app has its own sandbox which has a temporary directory.
The FileUtil::getSysTempDirectoryPath() method successfully gets this
directory and we create a tiledump directory under it. Sadly, we then
try to write to /tmp regardless of where the temporary directory is.
This commit makes us also write our file in the directory returned by
FileUtil::getSysTempDirectoryPath()
Signed-off-by: Skyler Grey <skyler.grey@collabora.com>
Change-Id: Ic8425cb94d1d85ac9c77212eb84d0ca7c46cd34e
skip deleting those jails for a few minutes to allow
the DocumentBroker to quarantine the document
Signed-off-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Change-Id: I781eeb77d491fe82a0bfe42eb09439c88f2454b7
and use online standard member prefix
Signed-off-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Change-Id: Ia7681870128185ecba27da0e344912e393e9114b
Instead of fighting the SolarMutex to get the messages
processed by the main loop. Simple and no additional
threading, mutexes etc.
messages from the external uno client are just
written to URPtoLoFD and the core reads from that
messages to the external uno client are written
to URPfromLoFD by core, that fd is in poll, and
activity there triggers a read by the DocBroker
to send it to the external uno client.
Signed-off-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Change-Id: Ib1f0a0d5fb5ab22eee476d5d740b290c51de59dc
- Allow COOLWSD client sessions to forward messages with the prefix
'urp' to the child, and return messages with 'urp:' to the client,
communicating with binary
- Make COOLWSD child sessions use the FunctionBasedURPConnection from
https://gerrit.libreoffice.org/c/core/+/155100
(core change ID I2bda3d0b988bef7883f9b6829eeb5b7ae8075f27) to start a
new URP session
- Make COOLWSD child sessions submit messages to this URP session,
stripping and adding the 'urp' and 'urp:' prefixes so the Java client
from https://gerrit.libreoffice.org/c/core/+/154680
(core change ID I91ee52922a24688a6b94512cb7e7bc760bf25ec9) can
use the connection (and to avoid interference with any other websocket
messages)
- Add a COOLWSD option for enabling/disabling URP given the security
implications around allowing anyone to write URP (e.g. URP lets you
run shell commands so a mallicious actor can take over the child
session)
Signed-off-by: Skyler Grey <skyler.grey@collabora.com>
Change-Id: Idadfe288a78cfd72b01253dfdade150d506e3f05
- it applies for 2 cases:
1. when document is loaded for the first time document already has
tiles of respective theme
2. when Kit loads the document it sends canonicalidchange unconditionally
(5520965b15/kit/Kit.cpp (L1708))
we don't need to request new tiles for that also
Signed-off-by: Rash419 <rashesh.padia@collabora.com>
Change-Id: I42cdc5a03e70c3d3d653f3124d3d5ed9382e22c0
in error branches dlclose unusable dso, leave it open on success
Signed-off-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Change-Id: I3a2eafceb573cc59ada922d98ae6a9b421d6accc
We assumed in the code that LO will return in a
LOK_CALLBACK_EXPORT_FILE url starting with "file:///tmp/"
But that is not true for all the cases. Let's use
more generic approach to extract file name.
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: Ib415f129b10c7e54172536f43a820e4bd3e9bfd2
and avoid local static in simd_initPixRowSimd
Signed-off-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Change-Id: Idb89d5069da5ff10b346b5e4d767374d4529a96f
This is to differentiate between a complete
trimming when idle compared to trimming
when inactive.
Change-Id: I61b309968e0a5199fe4f0fb445437a953c0e468a
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
Performance testing suggests that:
+ dense text this is 2x faster.
+ 'hello world' text this is 1.7x faster.
Change-Id: I4ff940663c44d0b22c9187deb4ee397a9d9953b0
Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
Simply calculate our loop variables from the iteration we're on.
Change-Id: I0bb73302fb09963b2a1f5b3d93ef302316ef1d4f
Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
Remove the special case for the first pixel, and instead have a
previous pixel run initialized to zero.
AVX2 has no effective shift for the while si256 so use permutation
to shift the last pixel of the previous run into the right place,
mask it and combine.
Saves a second un-aligned load of the same data, and branch.
Change-Id: I77c9cdead13d37aaf4d9f31d98cbd5c4a9c5ce24
Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
just enough to get the same results as before
https://github.com/CollaboraOnline/online/issues/7165
Signed-off-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Change-Id: I109c9b8f1e7935782c72e0179aa0ed48712eadb6
Split it out as a C file, to avoid accidental C++ header inclusion,
and C is a cross-platform assembler anyway so a good match.
Change-Id: I6c042781713aecaf143b9663af8377659a7deaf1
Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
Also rename trimIfExcessive to trimAfterInactivity.
Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
Change-Id: I62166a3ed5d70d1e6fd9804e91e07452978523fd