Commit graph

5544 commits

Author SHA1 Message Date
Tor Lillqvist
8e279c79f8 Don't do the security scope bookmark dance if not in a sandboxed process
No point in doing it in build-time tools like cppumaker which don't
run as sandboxed processes. Just slows them down a lot, while cfprefsd
consumes lots of CPU doing user preference lookups in vain for every
file accessed through the uunxapi functions.

Change-Id: I83e55a8e8d0c4f2c60c60ecad2c831e42c9e5bfd
2014-08-15 01:55:41 +03:00
Tor Lillqvist
2358ccec7e WaE: Unreferenced function definition
Change-Id: I1b5d3f881e82cea90fcc4e97c837251e340abffe
2014-08-13 11:48:07 +03:00
Thomas Arnhold
60fddc8731 textenc: disable failing tests on Windows for now
They were never working, at least since
65f82ca629

Which changed some mappings, for example:

-check( RTL_TEXTENCODING_IBM_437, RTL_TEXTENCODING_IBM_437 );
+check( RTL_TEXTENCODING_IBM_437, RTL_TEXTENCODING_MS_1252 );

But I don't know if that's the root of the problem.

Change-Id: I09f640a6c92a782f99d79405aab5f5dd2b992c6d
2014-08-13 10:10:55 +02:00
Thomas Arnhold
57fd10220a warning C4706: assignment within conditional expression
quite useful in this case

Change-Id: I2f9a5ef8ea9faf7a1ce62bd9b4925b3f36b19d1a
2014-08-13 10:10:55 +02:00
Thomas Arnhold
7cc627ff79 update_pch
Change-Id: Ic1dae7aac2f4367b4196ba3128c0aea9be1fbbda
2014-08-13 10:10:33 +02:00
Tor Lillqvist
ad85ce18d3 "fixes" needed because ure/source/unorc is now expanded at configure time
Argh, this is getting even uglier.

We cheerfully ignore for now the theoretical possibility that the URE
unorc used by build-time tools (i.e. the configure-expanded
ure/source/unorc) could be different for HOST and BUILD (in case they
use different --enable-canonical-installation-tree-structure), and use
the HOST one for the BUILD tools.

The right thing would probably be to construct the URE unorc in the
relevant Makefile, like we do for fundamentalrc? Or then to just
re-design the whole mess of rc files into some simpler (good luck).

Change-Id: I654309503d0e696778910acadcbf2f6b90ffa02a
2014-08-11 08:15:03 +03:00
David Tardon
71505177ba drop extra (
Change-Id: Ib1b6abf7a2aca80e7206d792d31f2cdd0fbe3ff8
2014-08-08 16:36:05 +02:00
Riccardo Magliocchetti
b471943640 osl: kill check for ancient freebsd < 7 versions
Change-Id: I082611edd88daae36181d62f9fc56b588630629b
Reviewed-on: https://gerrit.libreoffice.org/10828
Reviewed-by: Michael Stahl <mstahl@redhat.com>
Tested-by: Michael Stahl <mstahl@redhat.com>
2014-08-08 14:16:05 +00:00
Caolán McNamara
37276d1636 move null termination outside ifdefs for both branches
so the strncpy branch is guaranteed null terminated too

Change-Id: I79df96d69633a4db76f865301690c7ce7533fce9
2014-08-07 18:00:47 +01:00
Caolán McNamara
eb8d96fe7f coverity#706155 Copy into fixed size buffer
Change-Id: Ib795dc1b64d908942a836d09bfcde9f19d318b1b
2014-08-07 18:00:47 +01:00
Andrzej Hunt
533b9ab6fc osl_areCommandArgsSet: ensure mutexes locked when accessing data.
Change-Id: I6b1f10e74aafc47e5618290d92087563c60e3c49
2014-07-31 16:02:09 +02:00
Douglas Mencken
56c2802e1c sal_osl_process: fix "Parent and child environment not equal" for OSX <10.6
It fails with "assertion failed":
- Expression: compare_environments() [osl_process.cxx:370]
- Expression: compare_merged_environments(different_child_env_vars) [osl_process.cxx:428]

Just disable it (yet) for OSX <10.6 as it's already done for Windows.

Change-Id: I88e838481a25ee7e977512e33e23afa2b9d394ff
Reviewed-on: https://gerrit.libreoffice.org/10641
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Tested-by: Stephan Bergmann <sbergman@redhat.com>
2014-07-31 06:48:16 +00:00
Tor Lillqvist
a1ff2bb9a8 Include <algorithm> for std::min
Change-Id: I012027c38a6d2b06a4bb0cb53743d350b124ccf4
2014-07-28 09:46:17 +03:00
Michael Stahl
73b2ef39fc sal: avoid STL asserts in create_merged_environment
"Assertion failed: sequence not ordered" printed when running smoketest

Change-Id: Id9b7541f43342adf62137718dc332c0187c32f57
2014-07-24 00:34:50 +02:00
Caolán McNamara
0fc353a98f coverity#704665 Explicit null dereferenced
Change-Id: I45aa7a75b0780f6dd2fb3a5501b9541e7887a0d8
2014-07-19 21:26:00 +01:00
Michael Stahl
e8ec81d4bf sal: unx/mutex.c: try to avoid system declarations with _GNU_SOURCE
Apparently the __USE_UNIX98 that is required to get the goodies is not
defined for some reason; apply some brute force to get it defined
(we don't care about anything older than RHEL5's glibc 2.5 anyway).)

For mysterious reasons "system.h" defines __USE_GNU but not _GNU_SOURCE,
which appears odd...

Change-Id: I97d75050a6be7f393d5cdb686f1357da052109f7
Reviewed-on: https://gerrit.libreoffice.org/10301
Tested-by: LibreOffice gerrit bot <gerrit@libreoffice.org>
Reviewed-by: Michael Stahl <mstahl@redhat.com>
2014-07-15 19:04:45 +00:00
Noel Grandin
c14a3c1de2 workaround hack that trips up externandnotdefined clang plugin
Change-Id: I2f458cbd582c3e7cfe433915483c0b0489467471
2014-07-14 11:07:48 +02:00
Michael Meeks
231db56d02 sal: restore pthread to its original non-ideal state.
Hopefully repairs the tinderboxen.

Change-Id: I2933e6cbf1079a09dab48d4f7ed20b93634d8959
2014-07-12 12:14:58 +01:00
Noel Grandin
0a70789991 complete shot-in-the-dark to fix tinderbox build
tinderbox 50 is failing, trying to fix it

Change-Id: I81e3cbdb224110af3036f5726228fd88aba32748
2014-07-11 15:44:21 +02:00
Noel Grandin
0cca713f69 attempt to fix linux build
on some older boxes, after my commit
dac4ca5 "new loplugin: externalandnotdefined"

Change-Id: Ibcab5f39714fb531066709e91a7322270995a6a5
2014-07-11 14:40:18 +02:00
Noel Grandin
dac4ca5f68 new loplugin: externalandnotdefined
Find "missing headers," where a function is declared directly in the
.cxx (as extern) and not defined, and should arguably instead be declared
in an include file.

Change-Id: I6d83ee432b2ab0cd050aec2b27c3658d32ac02a2
2014-07-11 14:12:25 +02:00
Andrzej Hunt
7fd7b7af26 Introduce osl_areCommandArgsSet.
We cannot call osl_setCommandArgs twice, however there is currently
no way to determine whether or not this has already been done. This is
necessary e.g. for LibreOfficeKit where we may also be using UNO
separately (and also for unit tests where LO is already set-up prior
to the unit test running, and therefore we can't set up osl again
from within LOK).

Change-Id: Id1f357ef604eb2b6b7814c9a04ac6933a39fd3eb
2014-07-11 11:29:09 +01:00
Norbert Thiebaud
7f554464a1 coverity#982762 Dereference NULL
Change-Id: I9da66fe9cf279231d6024f23fbb273797b289ba7
2014-07-10 22:11:28 +02:00
Tor Lillqvist
b139eefeef Bypass CppunitTest_sal_osl_security with VS2013 for now, hangs
Change-Id: I8500b0cc4e541c96124425b713ba96226ff4715d
2014-07-08 11:38:54 +03:00
Tor Lillqvist
0dd717b139 Include <algorithm> for std::min() and max()
Change-Id: Ic3ab061ab8d3578130dfa8a637e5351d4f5d766e
2014-07-08 00:38:27 +03:00
Caolán McNamara
0d78ad871e DBG_ASSERT->assert when followed by dereference
Change-Id: Ic1c999ffdc391ea01be5711721e7c9e63179473e
2014-07-07 10:48:25 +01:00
Norbert Thiebaud
aa43602493 coverity#983493 String Overflow
Change-Id: I31a167508ca33e8d6ccc13690c013c39566b9447
2014-07-05 22:41:10 +02:00
Noel Grandin
281989007f Use standard library optimised routines for OUString/OString
..handling where possible.

Change-Id: I0b071988ed266cc2745a8ca9705c106a05edc557
Reviewed-on: https://gerrit.libreoffice.org/10020
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
2014-07-04 09:04:05 +00:00
Caolán McNamara
6da22e4148 coverity#1187696 Unintended sign extension
Change-Id: I8e56137ad4422381adbf13b179e2ae6f04edea6e
2014-07-03 14:52:23 +01:00
Stephan Bergmann
729d16f7f4 Use gb_CppunitTest_use_executable
Change-Id: I58b0d7d7a9a0ee78650b536b41154aee466f8ac5
2014-07-03 13:09:10 +02:00
Stephan Bergmann
4f90623dba Clean up surrogates.hxx
Change-Id: I0eae089be1bde9db822a77bea482c10650c8a137
2014-07-01 23:21:17 +02:00
Stephan Bergmann
e50ef195bc New loplugin:stringconcat
Change-Id: Id7c517fb37bc28797c45fc0dde83e866f2aa4aac
2014-07-01 15:45:52 +02:00
Jan Holesovsky
ed52e65bcb android: LibreOfficeKit needs the path to program/ as the starting point.
Change-Id: I7d4534649361e1bfa2c285e67e6765a4be55ec69
2014-07-01 13:48:28 +02:00
Caolán McNamara
5ace3f3b4f clang scan-build: various warnings
Change-Id: I4bdfb074b3cf6fcb49765322308dfa4b9ed67713
2014-07-01 10:56:14 +01:00
Tomaž Vajngerl
b046b687f9 lok bootstrap: nicer function names, clean-up
+ prevent lokandroid JNI functions to be removed from the library
+ basic use of lok Office / Document in LibreOfficeMainActivity

Change-Id: I7bfe53738cf821b2270ab3e024cc506a7cff42f0
2014-07-01 09:12:21 +02:00
Jan Holesovsky
c651bf9077 Actually not necessary to log this, it is already logged a bit later.
Change-Id: I30380b58b3141ac20e90e47a1538156b5b4dd08f
2014-07-01 07:58:08 +02:00
Jan Holesovsky
547135c0dc It is useful to know what macros are we expanding, and to what.
Change-Id: If7704edc5baa9759abc680b8d2040b9cdfe92317
2014-06-30 14:48:05 +02:00
Jan Holesovsky
cd77f78755 android: Enable debugging messages as the first thing we do.
Additionally log what we are trying to open - very useful for debugging
bootstrap problems ;-)

Change-Id: I942b144d97a57cbcb709b2d67029bfa09b339be2
2014-06-30 14:48:04 +02:00
Jan Holesovsky
c72d300ba0 android: Make the extract_files() part of setup / init.
We need to have the files extracted before we attempt to initialize
LibreOfficeKit (call libreofficekit_hook), otherwise the .rdb's are not there.

Change-Id: Ib49db7e945a709d18a063eb488a27df18fef542b
2014-06-30 14:48:03 +02:00
Jan Holesovsky
db89e5ff81 android: Make use of LibreOfficeKit.
Now the LibreOfficeKit is used to actually attempt to bootstrap LibreOffice;
at the moment fails to do that.

Change-Id: I91220dbff783213bf7702e7213a5646859db4581
2014-06-30 14:48:03 +02:00
Jan Holesovsky
74ab9835f9 android: Introduce LibreOfficeKit.java to bootstrap using LibreOfficeKit.
Change-Id: I5e1758c15684b06ab6809f62f4da6d5f50c071a9
2014-06-30 14:48:03 +02:00
Stephan Bergmann
9a741fcad4 loplugin:unreffun: also warn about unused function templates
Change-Id: I4a6280f47ca3c4a77b4e42fe05d79ded7fc30ef1
2014-06-27 07:51:51 +02:00
Stephan Bergmann
b7de76d825 Mac OS X does provide localtime_r and gmtime_r
Change-Id: I1142463972df76aac9e491abbfd08a67cf4db1f1
2014-06-26 17:55:05 +02:00
Stephan Bergmann
a15715c343 -Wstrict-prototypes
...no reason to not have it enabled for URE C include files and what
little real C code is still left.  (But note that Clang ignores that
warning.)

Change-Id: Ia6940f9f940a0c226e9b724331d65c9862ce32e6
2014-06-17 15:51:54 +02:00
Stephan Bergmann
97b330f016 loplugin:staticcall
Change-Id: Ia4111a0fb76c848d3bd2d01f3835995e4c007b6b
2014-06-13 17:54:30 +02:00
Caolán McNamara
2489589a64 coverity#982462 Dereference after null check
Change-Id: I5e90d51440afa4e317bc07ccb937f606edbc9eb9
2014-06-12 10:24:19 +01:00
Noel Grandin
e5c20a785c sal/rtl: remove SAL_THROW macro
Change-Id: I70e41f087dbe188f8fc455150480faeae2b426ed
2014-06-05 08:17:48 +02:00
Stephan Bergmann
b2725b7d1b Keep TestFixture alive until outputter is done with it
Change-Id: Ifd921efa971f7a9a5c47f42c5d56a3deb1c3a0b3
2014-06-04 11:05:58 +02:00
Stephan Bergmann
9e13afeaf6 Cover ctors/dtors of our TestFixtures under the protectors, too
Change-Id: I4c3030e5a205bd102d0427e74d2fe3b828ff5ae6
2014-06-04 08:55:12 +02:00
Jens Carl
f3e1f476e9 fdo#68849: Add header guards to all include files
Added header guards to files in directories sal/, sal/, and scripting/

Change-Id: Ieb7f224f2d27bd671618c516f47f5b7f08c1d294
Reviewed-on: https://gerrit.libreoffice.org/9582
Reviewed-by: Thomas Arnhold <thomas@arnhold.org>
Tested-by: Thomas Arnhold <thomas@arnhold.org>
2014-06-01 16:07:41 +00:00