Commit graph

10813 commits

Author SHA1 Message Date
Tomaž Vajngerl
c4fcb3eeb5 Fix build on android
Change-Id: I4cadfa38ffcaa774f6edf41a9172f1b4b5bbe896
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90203
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2020-03-09 11:31:30 +01:00
Miklos Vajna
a7d3efdd4e Introduce StringVector::equals()
Allows comparing tokens with C strings without a heap allocation. Do the
same when comparing two tokens from two different StringVectors.

And use it at all places where operator ==() has an argument, which is a
StringVector::operator []() result.

Change-Id: Id36eff96767ab99b235ecbd12fb14446a3efa869
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90201
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
2020-03-09 09:46:33 +01:00
Michael Meeks
7eea5b85ab Remove unused filterHandleRequest unit test hook.
Change-Id: Id1ff6005e28bf02eb9cad3c1609f9a8079640689
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90155
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2020-03-07 14:26:42 +01:00
Michael Meeks
019f268ffd handleDisconnect - unused.
Change-Id: Ib305f762ae33424c8a598d5c31eeda31b9c87555
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90137
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2020-03-07 11:28:08 +01:00
Pranam Lashkari
aea119edb7 Stop unnecessary calculation: ergonomic scrolling
Even when the document reached the boundary,
autoscrolling function was being called unnecessary
 until certain conditions are met
 this did not cause the document to scroll beyond the boundary
 bu it used to consume some CPU

 follow up for: https://gerrit.libreoffice.org/c/online/+/88072

Change-Id: I1cb6d6917c70de18af369d827e986a16eeb50c99
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/88421
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Henry Castro <hcastro@collabora.com>
2020-03-06 16:32:43 +01:00
Tamás Zolnai
b1b566c79f cypress: mobile: extend test of comment insertion.
Change-Id: Idb8539a353e884206b7e7b4885b60fa706f81d10
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90111
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-03-06 15:44:20 +01:00
Tamás Zolnai
8164c2cbc1 cypress: mobile: extend test of hyperlink insertion.
Change-Id: I433b819d5e76c56018fa15da539c48b1ceaeb022
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90110
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-03-06 15:31:03 +01:00
Tamás Zolnai
68924966c0 cypress: mobile: merge styles tests to font tests.
There is not much more we can test about styles,
since now we have only an apply style button.

Change-Id: I92a1a6dc60701743af44928966475cf4471b317b
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90108
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-03-06 15:19:34 +01:00
Pranam Lashkari
439ce089f2 leaflet: slide previews in impress adjusted to fit
In mobile vertical view impress slide previews were not visible

Change-Id: I24420577769e1124f9c7004ced54786522aa4bce
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89758
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Henry Castro <hcastro@collabora.com>
2020-03-06 14:52:19 +01:00
Henry Castro
e99f0da28d wsd: makefile: allow to set GDB Front Ends
Change-Id: I5b667938b25d8fe63d6c378cb383e357a071e134
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90022
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Henry Castro <hcastro@collabora.com>
2020-03-06 14:18:05 +01:00
Dennis Francis
824f48c447 On clicking last-sheet button, scroll to last tab
Before this patch, it used to scroll a fixed 120 px and does not
guarantee the visibility of the last tab especially if there are
lots of sheets in the document.

For scrolling to last tab, just use native scrollLeft attribute
rather than relying on jquery. On setting native scrollLeft to a
very high value, it ensures that it scrolls to the maximum possible
level (and shows the last tab) according to MDN scrollLeft documentation.

https://developer.mozilla.org/en-US/docs/Web/API/Element/scrollLeft

Sadly jquery documentation for its scrollLeft() does not mention
anything about the behaviour on setting a very high value(more than
maximum scroll), even though it appears to work.

Change-Id: I05142c1d3d63551fa2dc8359e41e30edc78a7d09
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89948
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Henry Castro <hcastro@collabora.com>
2020-03-06 14:15:10 +01:00
Henry Castro
7ba4e9dd23 wsd: debug: run the server with a single "lokit" process
Sometimes it is very useful to have one "lokit" process,
to focus on a 100% reproducible bug, and not worry
that server pre-spawn several processes.

Change-Id: I414a8145b53a0601a282cba9c245833f5d07f404
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89999
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Henry Castro <hcastro@collabora.com>
2020-03-06 13:37:53 +01:00
Dennis Francis
9d412a164e Remember the horizontal scroll position of calc tab-bar
Whenever the tab-bar contents are updated, restore the last
known scroll position.

This fixes a very annoying problem while selecting a sheet in
a document with many many sheets. Everytime the user selects a sheet
(closer to the last sheet), the tab-bar's scroll position is reset
to sheet#1, so if the user wants to select another sheet near the
last sheet, they have to scroll again a lot to see it.

Change-Id: I7e79b6e1a7b19223e1dbd9b3aab6c6f2b4d422b2
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89946
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Henry Castro <hcastro@collabora.com>
2020-03-06 13:33:32 +01:00
Miklos Vajna
1bfd7a363d libfuzzer: fix build
After commit f70e627795 (WebSocket -
simplify handleMessage for now., 2020-03-05).

Change-Id: Iac4be94fa1f9b37714329b6b6941c775c3fe1947
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90084
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2020-03-06 13:27:26 +01:00
Miklos Vajna
797c996c56 Fix -Werror,-Woverloaded-virtual warnings
Probably these were just not adapted by accident in commit
f70e627795 (WebSocket - simplify
handleMessage for now., 2020-03-05).

Change-Id: I578d95d938c0c466e9547dcda3d2b297dc347a34
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90076
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2020-03-06 11:31:43 +01:00
Tamás Zolnai
a0ce834641 cypress: mobile: fix random failure related to long press.
Change-Id: I61698639c0461c0acc6b2c97641d732b036a9d1b
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90061
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-03-05 21:15:23 +01:00
Andras Timar
59993fb9d1 docker: don't start another shell, let the loolwsd process have the PID 1
(Suggested by Ralf Becker)
e024a6c2a3 (r37648923)

Change-Id: Ifa519739686facb41eb9e85b68ebe547e008db34
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90019
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Andras Timar <andras.timar@collabora.com>
2020-03-05 21:11:30 +01:00
Michael Meeks
f70e627795 WebSocket - simplify handleMessage for now.
WebSocketHandler handles this complexity for us now, and for the
forseeable future. Simplify to prepare for larger re-factor.

Change-Id: I73b919885adc358cb6502a13492cdac85c34459c
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90059
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2020-03-05 20:28:48 +01:00
Michael Meeks
17cbb2b7b9 Session: simplify shutdown and privatize some pieces.
Change-Id: Ifbb40f6a88590bd87dbfada73fa26eb0b61705fb
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90058
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2020-03-05 20:22:32 +01:00
Michael Meeks
da944760a6 re-factor: move createNewSession into DocumentBroker.
Change-Id: I78f07a61fd79dfdd1c0d0ef21cf19218beec46ee
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90025
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2020-03-05 17:10:36 +01:00
Henry Castro
8a8eb43375 wsd: makefile: run server with disabled capabilities
fix runing the server with --disable-setcap, very useful
to debug when attaching kit process

Change-Id: I5ded5a1aa1924a9325ae76be46b32c0020d8ce35
WARNING: This is just for development and debugging purposes
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89970
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Henry Castro <hcastro@collabora.com>
2020-03-05 13:07:25 +01:00
Tamás Zolnai
6114b8c8ce cypress: mobile: enable some mobile wizard's state related checks.
Change-Id: I0bf19450f14e8e8d99e1a103558499d53f21f760
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89995
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-03-04 21:10:13 +01:00
Tamás Zolnai
883b28fbd5 cypress: mobile: re-enable some skipped tests.
Change-Id: I4163fdba2bc0fb7bcdc4d2b33f5deff6b0857013
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89960
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-03-04 13:58:33 +01:00
Henry Castro
c58b8dfdfc loleaflet: makefile: prefix m4_ builtin functions
Change-Id: I3605da8b44cec9855be39846de7f10feaf075f7d
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89890
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Tested-by: Henry Castro <hcastro@collabora.com>
Reviewed-by: Henry Castro <hcastro@collabora.com>
2020-03-04 13:30:41 +01:00
Tomaž Vajngerl
0897397834 android: create mainHandler on demand to prevent NPE
A crash happens when "back" is hit with a NPE exception because
mainHandler is null (not yet initilized). This changes the code
so mainHandler is initialized on demand and if not before, then
at least when initUI is called.

Change-Id: Id20b2093315ba41dac205fc4e94f31d00a4fe1f1
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89953
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2020-03-04 13:28:07 +01:00
Henry Castro
175cbdb3f4 loleaflet: makefile: use m4 to bundle all js files
It is a flexible bundling of all javascript libraries and
each platform (ANDROID, IOS, Desktop) can remove or add
from node_modules or imported according to its requirements.

Maybe in a near future some external libraries could be loaded
on demand or lazy loading that are not necessary when the page
is loading.

Change-Id: Ief5d4973ab29a4fb3c4848c3e1653a24fff0da69
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89860
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Tested-by: Henry Castro <hcastro@collabora.com>
Reviewed-by: Henry Castro <hcastro@collabora.com>
2020-03-03 18:21:10 +01:00
Tamás Zolnai
d9a23d9668 parallel-cypress: improve console output of parallel test run.
Change-Id: I29440bafdba101c3f4e86de7d587330b972289de
2020-03-03 16:00:30 +01:00
Tamás Zolnai
033e353e9d parallel-cypress: restore original sequential build.
Running all tests in one command will display a better output
and also might be faster.

Change-Id: Ib061fad28eeb1246c774bfb7fd958c3f5b9c317b
2020-03-03 12:41:54 +01:00
Yunusemre Şentürk
e18b7ca425 Wait until Xvfb says it is ready
Change-Id: I3af4428802d6e0ee380536e8dbad1de8aa6d9337
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89727
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-03-03 12:41:54 +01:00
Tamás Zolnai
2cfd990e75 parallel-cypress: Start own Xvfb in CI environment.
It's not necessary when we build with one job, but when
there are more jobs they try to start their own Xvfb
and they might use the same DISPLAY number for that
which leads to a failure or a freeze.
See also:
https://docs.cypress.io/guides/guides/continuous-integration.html#Xvfb

Change-Id: I2fb301b1d8e889b2898d6792fb38cece303129a6
2020-03-03 12:41:54 +01:00
Tamás Zolnai
eb3b3e54d4 parallel-cypress: during parallel build don't write out execution line-by-line
Because in this case, the output of the different threads will be
mixed in the command line.
For sequential build keep the original behavior.

Change-Id: Ibf9bf7c6111f8b5b0cf188fab66b97dedd613c65
2020-03-03 12:41:54 +01:00
Tamás Zolnai
be9277d700 parallel-cypress: initial parallelization
- Run all spec files separately so we can run them
in parallel.

Change-Id: I521feeac6e1ac4c3d2c87e989c11d4231945e568
2020-03-03 12:41:46 +01:00
Andras Timar
435f9b9fe5 tabs to spaces
Change-Id: Ia9372a09b5cca059fa59e18b7e46cf08268745bd
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89855
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Andras Timar <andras.timar@collabora.com>
2020-03-02 23:22:10 +01:00
Andras Timar
d04e1f4bd7 tabs to spaces
Change-Id: I8feb0f88e50c31ece6247b6f1c940b5cef8ed420
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89853
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Andras Timar <andras.timar@collabora.com>
2020-03-02 21:54:36 +01:00
Andras Timar
d1992e0e62 Base documents and Extensions are not supported
Change-Id: I7fc728e9da03ad2b1f6811d7a03307f2d3876b31
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89812
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
2020-03-02 21:21:21 +01:00
mert
41d065af2a Fix hyperlinkclicked message is not properly parsed
$.inArray does not work because the parsed msg
is not an array
Change-Id: I68a8312da17b0832b09a88afeaf05ad75a2c6e2d
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89833
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Andras Timar <andras.timar@collabora.com>
2020-03-02 20:50:59 +01:00
Pedro Pinto Silva
a47db54ea5 Mobile: mobileWizard: Impress: add iconpath according to its id from unocomands coming from core for this case specific
Change-Id: I5f91790528a71e8bff5de58b0d3988aa305c02c5
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89635
Reviewed-by: Pedro Pinto da Silva <pedro.silva@collabora.com>
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
2020-03-02 20:02:39 +01:00
Tomaž Vajngerl
65a19d4e21 android: reuse an already open activity when starting a new one
This sets the "launchMode" of the LOActivity to "singleTask" and
implements "onNewIntent". This is necessary so that we don't
duplicate LOActivity instances, as that isn't handled correctly
and can cause a freeze or in some cases that text input from one
instance is sent to the other. The back button stack isn't ideal
as it still can return us to LibreOfficeUIActivity even when the
activity is started from some other app, but this at least is
consistent with how some other apps work.

Change-Id: Idd11214578ec124661e2612bb49ba7e4bc4f3cea
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89811
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
2020-03-02 19:04:55 +01:00
Pranam Lashkari
e30b035136 leaflet: removed legacy inertia scrolling implementation
Change-Id: I6be07f1d16ea6bcebfa9c8c2712b713c3f0b1950
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89772
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Henry Castro <hcastro@collabora.com>
2020-03-02 16:53:19 +01:00
Henry Castro
3697315349 loleaflet: makefile: use m4 to bundle src js files
It is a flexible bundling of the loleafet source files
and each platform (ANDROID, IOS, DESKTOP) can prevent to
bundle some files that is not necessary.

(i.e Mouse handling in native mobile devices)

Change-Id: If018bcc8682df5ae4bf5dd9943aa977e18c0de36
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89734
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Tested-by: Henry Castro <hcastro@collabora.com>
Reviewed-by: Henry Castro <hcastro@collabora.com>
2020-03-02 16:51:32 +01:00
Miklos Vajna
c99664b19c StringVector: fix build with gcc-4.9
Debian 8 has gcc-4.9, which emits -Werror in case a parameter and a
member function has the same name. Given that we also use -Werror
unconditionally, this breaks the build. Newer gcc/clang versions relaxed
this warning, so this was not a problem in those cases.

Change-Id: I7ad09370d96aa7384b2c117dd8de421644898b50
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89785
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2020-03-02 16:25:05 +01:00
Marco Marinello
11c12a2729 Variabilize online git source
Signed-off-by: Marco Marinello <marinello@libreoffice.org>
Change-Id: If8f9103972952b98193ca6d1501844422b8aae54
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89483
Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2020-03-02 01:53:29 +01:00
Jan Holesovsky
0acb00fc24 android: Handle the loading progress directly in the app.
This way we can easily extend the "preparing for the 1st start" to the
follow-up "loading..."

It should also look better while the webview is being initialized etc.

Change-Id: I8de2dd96a726fa8302df558f691b1db82c9c8e71
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89733
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2020-02-29 11:03:42 +01:00
Jan Holesovsky
a5410a126f android: No need for a USB device attached/detached receiver any more.
This was needed before we switched to using the Content provider
framework.

Change-Id: I3906069ad3dc04a957f768b9ed02463aeaa4470f
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89732
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2020-02-29 11:03:14 +01:00
Jan Holesovsky
48283deca5 Just try to catch everything in the getSafeConfig().
Poco::Exception is derived from std::exception, yet there were cases
where it was not caught - no idea why:

I/DEBUG   (24700):     #00 pc 000371e4  /system/lib/libc.so (tgkill+12)
I/DEBUG   (24700):     #01 pc 00013fb9  /system/lib/libc.so (pthread_kill+52)
I/DEBUG   (24700):     #02 pc 00014bd7  /system/lib/libc.so (raise+10)
I/DEBUG   (24700):     #03 pc 00011519  /system/lib/libc.so (__libc_android_abort+36)
I/DEBUG   (24700):     #04 pc 0000fca4  /system/lib/libc.so (abort+4)
I/DEBUG   (24700):     #05 pc 000126e9  /system/lib/libc.so (__libc_fatal+16)
I/DEBUG   (24700):     #06 pc 0001159d  /system/lib/libc.so (__assert2+20)
I/DEBUG   (24700):     #07 pc 00064fed  /data/app/com.collabora.libreoffice-1/lib/arm/libc++_shared.so
I/DEBUG   (24700):     #08 pc 00065183  /data/app/com.collabora.libreoffice-1/lib/arm/libc++_shared.so
I/DEBUG   (24700):     #09 pc 0006cb79  /data/app/com.collabora.libreoffice-1/lib/arm/libc++_shared.so
I/DEBUG   (24700):     #10 pc 0006c527  /data/app/com.collabora.libreoffice-1/lib/arm/libc++_shared.so
I/DEBUG   (24700):     #11 pc 0006c4ef  /data/app/com.collabora.libreoffice-1/lib/arm/libc++_shared.so (__cxa_throw+74)
I/DEBUG   (24700):     #12 pc 001be25c  /data/app/com.collabora.libreoffice-1/lib/arm/libandroidapp.so (_ZNK4Poco4Util21AbstractConfiguration7getBoolERKNSt6__ndk112basic_stringIcNS2_11char_traitsIcEENS2_9allocatorIcEEEE+208)
I/DEBUG   (24700):     #13 pc 001847fd  /data/app/com.collabora.libreoffice-1/lib/arm/libandroidapp.so (_ZN7LOOLWSD17ConfigValueGetterclERb+12)
I/DEBUG   (24700):     #14 pc 001847c3  /data/app/com.collabora.libreoffice-1/lib/arm/libandroidapp.so (_ZN7LOOLWSD13getSafeConfigIbEEbRN4Poco4Util20LayeredConfigurationERKNSt6__ndk112basic_stringIcNS5_11char_traitsIcEENS5_9allocatorIcEEEERT_+22)
I/DEBUG   (24700):     #15 pc 00184747  /data/app/com.collabora.libreoffice-1/lib/arm/libandroidapp.so (_ZN7LOOLWSD14getConfigValueIbEET_RN4Poco4Util20LayeredConfigurationERKNSt6__ndk112basic_stringIcNS6_11char_traitsIcEENS6_9allocatorIcEEEES1_+38)
I/DEBUG   (24700):     #16 pc 0018748b  /data/app/com.collabora.libreoffice-1/lib/arm/libandroidapp.so (_ZN7LOOLWSD10initializeERN4Poco4Util11ApplicationE+1334)
I/DEBUG   (24700):     #17 pc 001c7274  /data/app/com.collabora.libreoffice-1/lib/arm/libandroidapp.so (_ZN4Poco4Util11Application3runEv+28)
I/DEBUG   (24700):     #18 pc 00134fbf  /data/app/com.collabora.libreoffice-1/lib/arm/libandroidapp.so
I/DEBUG   (24700):     #19 pc 00134df7  /data/app/com.collabora.libreoffice-1/lib/arm/libandroidapp.so
I/DEBUG   (24700):     #20 pc 00134dc5  /data/app/com.collabora.libreoffice-1/lib/arm/libandroidapp.so
I/DEBUG   (24700):     #21 pc 000137a3  /system/lib/libc.so (_ZL15__pthread_startPv+30)
I/DEBUG   (24700):     #22 pc 00011883  /system/lib/libc.so (__start_thread+6)

Change-Id: Ica643f88d572b239b9a124e31cb4552f86439bf6
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89715
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2020-02-29 11:02:52 +01:00
Jan Holesovsky
09005eb1cf android: Don't even try to read these values, seem to trigger an exception.
All the code that is using them is compiled out on Android anyway.

Change-Id: Ica349135202211ecdcb095bb82aa677f2dee19ba
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89714
Tested-by: Michael Meeks <michael.meeks@collabora.com>
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2020-02-29 11:01:00 +01:00
Miklos Vajna
7193699742 libfuzzer: don't require a core.git installation set
The fuzzer focuses on catching protocol parsing problems, it's not an
end-to-end test.

Change-Id: I1edc308134f365749339790f242614332b54dce4
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89720
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2020-02-28 18:31:53 +01:00
Miklos Vajna
547f9ea731 Rework StringVector to have a single underlying string
This is meant to reduce lots of small allocations and instead have
pointers into the single string for the various tokens instead.

This has a few requirements, though:

1) It's no longer OK to modify the tokens, changing their length would
invalidate the start/length of other tokens. Rework
DocumentBroker::load() to avoid such mutation.

2) The iterators no longer expose zero-terminated strings, so
Poco::cat() doesn't work anymore: add an own cat() instead and use that
in e.g. ChildSession. The own cat() has the benefit that it won't read
past the end of the array if the begin index is out of bounds to add
more safety.

(This nicely works towards killing Poco usage in general.)

3) If zero-terminated strings for all individual tokens is needed, a
copy has to be made, as done in spawnProcess().

(For all of these requirements, the build fails if there are problems.)

Change-Id: Iea40e4400e630b2d669f5c72aea85cb40edf9a2c
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89711
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
2020-02-28 18:31:37 +01:00
Miklos Vajna
b8bd1990aa Rework LOOLProtocol::tokenize() to return a StringVector object
The bulk of this commit just changes std::vector<std::string> to
StringVector when we deal with tokens from a websocket message.

The less boring part of it is the new StringVector class, which is a
wrapper around std::vector<std::string>, and provides the same API,
except that operator[] returns a string, not a string&, and this allows
returning an empty string in case that prevents reading past the end of
the underlying array.

This means in case client code forgets to check size() before invoking
operator[], we don't crash. (See the ~3 previous commits which fixed
such crashes.)

Later the ctor could be changed to take a single underlying string to
avoid lots of tiny allocations, that's not yet done in this commit.

Change-Id: I8a6082143a8ac0b65824f574b32104d7889c184f
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89687
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2020-02-28 16:07:56 +01:00
Henry Castro
133dee2980 loleaflet: makefile: avoid to execute javascript to get a list file
We are in state to bundle Javacript files for different platforms:
Android, IOS, desktop. And each platform could add specific chunk
Javascript code according its specific requirements.

Change-Id: Ib52ae816cb9443c8605fdf70aaa4c5e4c81b962d
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89557
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Tested-by: Henry Castro <hcastro@collabora.com>
Reviewed-by: Henry Castro <hcastro@collabora.com>
2020-02-28 13:46:18 +01:00