836 Commits

Author SHA1 Message Date
Stephan Bergmann
6291574d94 Remove unused #include <ctype.h>
Change-Id: I8bf3e30687e20151a9e1936e69362abfe9b3a99d
2017-03-23 17:55:31 +01:00
Stephan Bergmann
25ecb6f627 Use rtl::isAscii* instead of ctype.h is* (and fix passing plain char)
Change-Id: I18f9a2ad4506edc76b74dde229f2fd296bffed88
2017-03-22 21:40:55 +01:00
Michael Stahl
2aa20cfb7a jvmfwk: fix JVM detection on 64-bit Windows
_WIN32 is also defined on 64-bit Windows so reorder these ifdefs.

Should i be surprised that this breaks several dbaccess tests
for me but all tinderboxes are green?

(regression from 9143dd4ebe37b608e43d04434cf831624bf55b65)

Change-Id: Id917952d3135768355af711688ff70bf6c019a6e
2017-03-22 10:30:41 +01:00
Julien Nabet
0a57e51f41 Fix typo for "expression"
Change-Id: Iad0728fe53912d85ee40ef1b39d476a47aaad2d2
Reviewed-on: https://gerrit.libreoffice.org/35433
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2017-03-19 17:25:49 +00:00
Stephan Bergmann
849c82495e Unnecessary OUString instances
Change-Id: I81a59c7847e2109198a35cbdb49f5bcf3505c4ba
2017-03-13 17:43:38 +01:00
Samuel Mehrbrodt
9143dd4ebe Related tdf#54443 List only matching JREs
I.e. show only 64bit JRE for 64bit LO and 32bit JRE for 32bit LO

Change-Id: Id5e890637c7e1014bcb4e6fdd9ed9a33765112d5
Reviewed-on: https://gerrit.libreoffice.org/35026
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2017-03-13 08:16:32 +00:00
Samuel Mehrbrodt
89bfaa58e5 jvmfwk: Improve logging output
Change-Id: I476fc3190902e44bedfd2e713bd1a7cfb0733688
Reviewed-on: https://gerrit.libreoffice.org/35024
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2017-03-09 19:57:07 +00:00
Stephan Bergmann
6cb9e6dad7 Remove redundant 'inline' keyword
...from function definitions occurring within class definitions.  Done with
a rewriting Clang plugin (to be pushed later).

Change-Id: I9c6f2818a57ccdb361548895a7743107cbacdff8
Reviewed-on: https://gerrit.libreoffice.org/34874
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2017-03-03 20:55:50 +00:00
Samuel Mehrbrodt
64a50fc271 Typo: requirments -> requirements
Change-Id: I02c5846eb51071e1a958c3d65e150fb7cbc7d58a
Reviewed-on: https://gerrit.libreoffice.org/34873
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2017-03-03 16:43:59 +00:00
Andrea Gelmini
5bea199bae Fix typos
Change-Id: Ic6c41fbcc36c11a7528cde0986593a39c2d6738b
Reviewed-on: https://gerrit.libreoffice.org/34803
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-03-02 12:39:35 +00:00
Stephan Bergmann
f21994e7a2 Make JVM -Xrunjdwp option work on macOS
I hope loading the jvm library as SAL_LOADMODULE_GLOBAL has no negative
consequences (at least, there is prior art in the LINUX case already).

Change-Id: If18b65bd96f7205fdf9fd41389e64e786c15af16
2017-02-24 17:00:28 +01:00
Noel Grandin
c5df32e5cb loplugin: unnecessary destructor jvmfwk..lotuswordpro
Change-Id: Iaa4f9b178ab265342255066af7fff09f5b33ab37
Reviewed-on: https://gerrit.libreoffice.org/33496
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-01-24 15:56:31 +00:00
Michael Stahl
0cee740c95 replace #ifdef SOLARIS with #ifdef __sun
Check for a macro that is defined by the compiler, we don't really need
one defined by the build system.

Change-Id: Iccb8e3198396881395c97a6b81690ebe64b7e9d2
2017-01-17 16:38:33 +01:00
Noel Grandin
90df5ee107 new loplugin: useuniqueptr: jvmfwk..sax
Change-Id: I732e2e22c6f953f0982fbc8833453e7c23cf9d49
Reviewed-on: https://gerrit.libreoffice.org/33166
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-01-17 06:41:54 +00:00
Stephan Bergmann
884437ef2e New loplugin:externvar: jvmfwk
Change-Id: I0fee834ba07ecdc713e0e066935773f49a109665
2017-01-09 15:42:37 +01:00
tamsil1amani3
7a07610588 tdf#95416 Fix include file
Moved elements.hxx and fwkutil.hxx to jvmfwk/inc and changed the #include line in vendorplugin.hxx

Change-Id: Ida7395e952c482af92c0561a7756be7cd0578b9f
Reviewed-on: https://gerrit.libreoffice.org/32415
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: jan iversen <jani@documentfoundation.org>
2016-12-25 07:35:12 +00:00
Stephan Bergmann
36a329b639 Fix regression in bubbleSortVersion
...introduced with 789055bc2acb4c71483fd60ea258d158bd5aec10 "clang-tidy
performance-unnecessary-copy-initialization" (so partially revert it).  Whatever
clang-tidy erroneously reported there, cur and next are lvalue references into
vec, so this attempted copy now actually overwrote one with the other.  The
result was that if multiple JREs are detected on the system, "Options -
LibreOffice - Advanced" would list a single one multiple times.

Change-Id: I7ef454c0f37669722812383848602dc2bacf7cd1
2016-11-16 23:47:09 +01:00
Stephan Bergmann
36c8fd8995 Clean up jfw_findAllJREs return value computation
Change-Id: Iace2281ec4b5cfaa6e1de44b58a6705ca3a18c58
2016-11-16 23:47:09 +01:00
Noel Grandin
990102be61 loplugin:unnecessaryvirtual in hwpfilter..rsc
Change-Id: I2e9df8223d503b813b4c458747e8c44bb8ef8868
Reviewed-on: https://gerrit.libreoffice.org/30661
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2016-11-08 06:10:25 +00:00
Stephan Bergmann
f861c29e4c Clean up javavendors_*.xml files
...and drop unnecessary javavendors_template.xml

Change-Id: Ib7f2d595d2086c1d3bf324f19693b9032cf00cd7
2016-11-01 22:28:37 +01:00
Stephan Bergmann
f537e561c7 quickfix: Automatic selection of Oracle Java runtime on macOS
same issue as 36f637f7f21906fa3f37223e69b044db52036fb1 "tdf#103507 quickfix:
Automatic selection of Oracle Java runtime on Windows"

Change-Id: I3239bbf52263fb53bcd0ed54e8e983bda3b19182
2016-11-01 21:17:48 +01:00
Stephan Bergmann
36f637f7f2 tdf#103507 quickfix: Automatic selection of Oracle Java runtime on Windows
...which had been broken since 5e9a2e9b0f33ab50aa3a84728db75383aede19d9 "Check
each potential JRE location only once", as jfw_findAndSelectJRE calls
jfw_plugin_getAllJavaInfos on each vendor in turn, but that now only operates on
any items newly added by addAllJREInfos, so the first call to
jfw_plugin_getAllJavaInfos (with sVendor being "Sun Microsystems Inc."
unsuccesfully operated on all items, and the next call (with sVendor being
"Oracle Corporation") didn't see any further items to operate on.

So the quickfix (at least for any Java runtimes by Oracle) is to reorder the
vendors in javavendors_wnt.xml.  The proper fix will be to reorder the code so
it obtains the list of all Java runtimes only once, and then matches that list
against the known vendors.

(Other plaforms appear not to be affected by this issue.  Some
jvmfwk/distributions/OpenOfficeorg/javavendors_*.xml already sort Oracle first,
anyway.  And e.g. on Linux, jfw_findAndSelectJRE typically already succeeds with
calling jfw_plugin_getJavaInfosFromPath and so doesn't reach the problematic
code.

Change-Id: Ied571ae1d4745d53ce0c8697d0f1b268e1aac407
2016-10-28 11:17:10 +02:00
Stephan Bergmann
1ccc7c425b clang-cl loplugin: jvmfwk
Change-Id: I4ae0795469e70d6be3d2052d96a2f0dad3920d8b
Reviewed-on: https://gerrit.libreoffice.org/29860
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2016-10-16 14:18:35 +00:00
Stephan Bergmann
91dd2db17b loplugin:override: No more need for the "MSVC dtor override" workaround
The issue of 362d4f0cd4e50111edfae9d30c90602c37ed65a2 "Explicitly mark
overriding destructors as 'virtual'" appears to no longer be a problem with
MSVC 2013.

(The little change in the rewriting code of compilerplugins/clang/override.cxx
was necessary to prevent an endless loop when adding "override" to

  OOO_DLLPUBLIC_CHARTTOOLS    virtual ~CloseableLifeTimeManager();

in chart2/source/inc/LifeTime.hxx, getting stuck in the leading
OOO_DLLPUBLIC_CHARTTOOLS macro.  Can't remember what that
isAtEndOfImmediateMacroExpansion thing was originally necessary for, anyway.)

Change-Id: I534c634504d7216b9bb632c2775c04eaf27e927e
2016-09-13 13:19:22 +02:00
James Clarke
3cb45765f2 (initial) sparc64 port
Change-Id: I8ec9bb5415a9e6b9083ba89a7790872d67625de1
2016-08-05 18:09:59 +02:00
Caolán McNamara
a3b3c5fcd7 Related: tdf#101057 inherit MalformedVersionException from std::exception
so we don't get std::terminate on MacOSX if its thrown up to
JavaVirtualMachine::getJavaVM

Change-Id: I1c6b79bf16cbaa66b8f79d495239e301d3ca58de
2016-07-22 21:40:40 +01:00
Caolán McNamara
64d3270a89 Related: tdf#101057 allow java update version number > 99
Change-Id: Icc37cf248fbf35f108eb5bbb25c36fbd54a9fe85
2016-07-22 08:23:18 +01:00
Stephan Bergmann
1b2a4dd785 loplugin:redundantcast: redundant static_casts in jvmfwk
Change-Id: I6aef36bd21043460e74b5e3d478665a35213bb1a
2016-07-08 16:47:31 +02:00
Otto Kekäläinen
428e23f4f7 Fix some spelling errors in comments and strings
Change-Id: Iecd6b5e13d6be14651f77d8e37f01117ba15a11e
Reviewed-on: https://gerrit.libreoffice.org/26883
Reviewed-by: jan iversen <jani@documentfoundation.org>
Tested-by: jan iversen <jani@documentfoundation.org>
2016-07-04 06:11:36 +00:00
Markus Mohrhard
b5876bfcb6 passing a NULL pointer to fileno is not allowed
See crash reports at
http://crashreport.libreoffice.org/stats/signature/do_msvcr_magic+0x7
and documentation at
https://msdn.microsoft.com/en-us/library/zs6wbdhx.aspx

Change-Id: Ia9166d3b9fa10b87585821504e39cdfecbd22eda
Reviewed-on: https://gerrit.libreoffice.org/26317
Reviewed-by: Michael Stahl <mstahl@redhat.com>
Tested-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
2016-06-15 19:52:10 +00:00
Noel Grandin
57ef4457be Convert javaPluginError to scoped enum
Change-Id: Ib3a32227d50fa9e0f9cc4106ce40a4c3e840f8c7
Reviewed-on: https://gerrit.libreoffice.org/25206
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-05-22 17:52:41 +00:00
Stephan Bergmann
bade0a1517 Add SAL_FALLTHROUGH, where apparently appropriate
Change-Id: I0dccdf984f4b171feab20e8400376cf8846ffe2e
2016-05-10 17:02:32 +02:00
Stephan Bergmann
14cd5182c5 Replace fallthrough comments with new SAL_FALLTHROUGH macro
...which (in LIBO_INTERNAL_ONLY) for Clang expands to [[clang::fallthrough]] in
preparation of enabling -Wimplicit-fallthrough.  (This is only relevant for
C++11, as neither C nor old C++ has a way to annotate intended fallthroughs.)

Could use BOOST_FALLTHROUGH instead of introducing our own SAL_FALLTHROUGH, but
that would require adding back in dependencies on boost_headers to many
libraries where we carefully removed any remaining Boost dependencies only
recently.  (At least make SAL_FALLTHROUGH strictly LIBO_INTERNAL_ONLY, so its
future evolution will not have any impact on the stable URE interface.)  C++17
will have a proper [[fallthroug]], eventually removing the need for a macro
altogether.

Change-Id: I342a7610a107db7d7a344ea9cbddfd9714d7e9ca
2016-05-10 16:42:16 +02:00
Andrea Gelmini
fc2590cfa1 Fix typos
Change-Id: Id81b16ff26283611f0b84929d831c827f847ab73
Reviewed-on: https://gerrit.libreoffice.org/24317
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
2016-04-30 15:06:45 +00:00
Noel Grandin
e8fd5a07ec update loplugin stylepolice to check local pointers vars
are actually pointer vars.

Also convert from regex to normal code, so we can enable this
plugin all the time.

Change-Id: Ie36a25ecba61c18f99c77c77646d6459a443cbd1
Reviewed-on: https://gerrit.libreoffice.org/24391
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-04-26 10:55:58 +00:00
Stephan Bergmann
f43b89b7ed loplugin:salbool: Automatic rewrite of sal_False/True
Change-Id: I65fdd933e2a3973053359024d8d9c733f79a6477
2016-04-20 17:25:43 +02:00
Noel Grandin
789055bc2a clang-tidy performance-unnecessary-copy-initialization
probably not much performance benefit, but it sure is good at
identifying leftover intermediate variables from previous
refactorings.

Change-Id: I3ce16fe496ac2733c1cb0a35f74c0fc9193cc657
Reviewed-on: https://gerrit.libreoffice.org/24026
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Tested-by: Noel Grandin <noelgrandin@gmail.com>
2016-04-18 07:37:31 +00:00
Noel Grandin
62633dfe02 clang-tidy performance-unnecessary-value-param in various
Change-Id: I7168d44dab8e6a8e37bb7920d744ff32f5e52907
Reviewed-on: https://gerrit.libreoffice.org/24019
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-04-14 11:37:19 +00:00
Jochen Nitschke
4c7ec9f112 cleanup: remove unused com/sun/star/uno includes
Sequence.h(xx), Any.h(xx) and Type.h(xx)
and remove unused using-declarations from these files.

Add a few missing includes provided by them.

Change-Id: I6b91b6d1fdf9d0496dd546c0aab9bdcc6831a5d4
Reviewed-on: https://gerrit.libreoffice.org/23805
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-04-12 06:38:26 +00:00
Jochen Nitschke
d84ef731d8 tdf#94306 replace boost::noncopyable ...
... in modules editeng to oox.
Replace with C++11 delete copy-constructur and
copy-assignment.
Remove boost/noncopyable.hpp includes and
one unused boost/checked_delete.hpp include in linguistic.

Change-Id: I5a38d8e5ac1b4286bdeb3858d56490a53d13fe80
Reviewed-on: https://gerrit.libreoffice.org/23928
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-04-11 07:22:50 +00:00
Stephan Bergmann
6858d559fe Values read from the Windows registry shouldn't be assert'ed
Change-Id: I1a6cc78025790fa22e91ae91dda5644bdc384ca3
2016-04-05 17:05:34 +02:00
Rohan Kumar
20efe5ebcb tdf#91794 remove OSL_DEBUG_LEVEL > 1 conditionals
I replaced OSL_ASSERT() with standard C++ assert

Change-Id: I92e07d62f3dfe2ad914c49e2b596aef28c35e225
Reviewed-on: https://gerrit.libreoffice.org/23231
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Björn Michaelsen <bjoern.michaelsen@canonical.com>
2016-03-15 00:18:50 +00:00
Stephan Bergmann
eee4dd746e Fix memory leaks
Change-Id: If9f7dc4a28d5e005959f0d4a0a2ed317b699f292
2016-03-10 21:43:13 +01:00
Stephan Bergmann
8e9a7cac42 No more need for jfw_freeJavaInfo
Change-Id: I2426a76936b4099a243ce8c102da867e7868aac3
2016-03-10 21:42:31 +01:00
Stephan Bergmann
8546831b3b Turn JavaInfo sal_Sequence* member into rtl::ByteSequence
Change-Id: Iecd476970b0b7a46afe223f71e95b0010048d7b1
2016-03-10 21:41:24 +01:00
Stephan Bergmann
5dcdb35ab1 Turn JavaInfo rtl_uString* members into OUString
Change-Id: Ieb23b0c36ef56a4793a56cdb450df34e4d9bce1d
2016-03-10 21:41:24 +01:00
Stephan Bergmann
81dd7115e8 Manage JavaInfo instances via new/delete
Change-Id: I10a113718e525b646c51aa8a19f9f2b75a36714a
2016-03-10 21:41:23 +01:00
Stephan Bergmann
bf6c5c9b0f No need to repeat SAL_CALL in definitions
Change-Id: Ief75af9d08d9b7e31d821773db2363fa201f3038
2016-03-10 21:41:23 +01:00
Stephan Bergmann
8471ba7b97 No need for extern "C" here
...and fix resulting loplugin:salbool fallout

Change-Id: I5ae1497608d31c20b0d10676450a7673dee1c651
2016-03-10 21:41:22 +01:00
Stephan Bergmann
220d9c24d0 include/jvmfwk/*.h -> .hxx (only ever included from C++ code)
Change-Id: Ia912e937d5a48afb6f8f5345b20bb7bd517fc4f1
2016-03-09 19:08:29 +01:00