Commit graph

1000 commits

Author SHA1 Message Date
Luboš Luňák
6080259862 allow using rtl::OUString etc. simply as OUString, without rtl::
http://lists.freedesktop.org/archives/libreoffice/2012-April/029940.html

The RTL_USING #define (set by gbuild for anything that's not public
API) allows to use such classes simply by their name, without having
to use the namespace or do explicit using rtl::OUString (which half
of the sources do anyway).

Change-Id: I7edaf12cd278489cdc1d5ff782f0a86361c13c0a
2012-07-16 16:03:03 +02:00
Thomas Arnhold
1340890ccd simplify include guards
Change-Id: Id4210229b20a1d54b680ff1a2ccbcdd3684ecf5f
2012-07-14 05:44:15 +02:00
Caolán McNamara
73f453bd11 just use rtl::OUString::createFromAscii
Change-Id: I425e7bcc8f81b2d67a98244ba4419ace1ba569ec
2012-07-03 21:21:09 +01:00
Caolán McNamara
7d851250e5 we don't need to check for complete length, any non 0 length will do
Change-Id: I6978524ef934ee97d151e0fd22f3a0dfc91fd26e
2012-07-03 21:21:09 +01:00
Michael Meeks
fdda178d88 targetted improvement of UNO API includes / usage 2012-07-02 14:43:34 +01:00
Thomas Arnhold
0f11f30ea9 Remove unused header files
Those are unused too.

Change-Id: I09c9dbcdbc68131c7c54bf0762a23f1280e6e22a
2012-06-28 11:08:49 +02:00
Michael Meeks
328e2263fb targetted re-work of cppunit pieces. 2012-06-27 19:13:11 +01:00
Michael Meeks
46b8dbda43 re-base on ALv2 code. 2012-06-26 21:48:59 +01:00
Michael Meeks
ec5fa0164b replace all but one .hdl include with equivalent .hpp includes.
Change-Id: I15e94f112144549692d0c2babeb48c77adcb93a9
2012-06-21 19:28:47 +01:00
Caolán McNamara
57ea40b8b6 WaE: clear higher debugging levels warnings
Change-Id: I611dc412b5461f368f23aa8239e48d0e175f5168
2012-06-15 15:41:12 +01:00
Michael Meeks
c3a6a57fc2 re-base on ALv2 code. 2012-06-13 14:18:29 +01:00
Michael Meeks
544c785c13 quiet potential size warnings. 2012-06-13 14:09:19 +01:00
Michael Meeks
aa00f6f1ce targetted sb140 revert. 2012-06-13 14:09:19 +01:00
Stephan Bergmann
2fa2660b55 Better fix for ThreadPool/ORequestThread life cycle
This is a follow up to d015384e1d "Fixed
ThreadPool (and dependent ORequestThread) life cycle" that still had some
problems:

* First, if Bridge::terminate was first entered from the reader or writer
thread, it would not join on that thread, so that thread could still be running
during exit.

That has been addressed by giving Bridge::dispose new semantics:  It waits until
both Bridge::terminate has completed (even if that was called from a different
thread) and all spawned threads (reader, writer, ORequestThread workers) have
been joined.  (This implies that Bridge::dispose must not be called from such a
thread, to avoid deadlock.)

* Second, if Bridge::terminate was first entered from an ORequestThread, the
call to uno_threadpool_dispose(0) to join on all such worker threads could
deadlock.

That has been addressed by making the last call to uno_threadpool_destroy wait
to join on all worker threads, and by calling uno_threadpool_destroy only from
the final Bridge::terminate (from Bridge::dispose), to avoid deadlock.  (The
special semantics of uno_threadpool_dispose(0) are no longer needed and have
been removed, as they conflicted with the fix for the third problem below.)

* Third, once uno_threadpool_destroy had called uno_threadpool_dispose(0), the
ThreadAdmin singleton had been disposed, so no new remote bridges could
successfully be created afterwards.

That has been addressed by making ThreadAdmin a member of ThreadPool, and making
(only) those uno_ThreadPool handles with overlapping life spans share one
ThreadPool instance (which thus is no longer a singleton, either).
Additionally, ORequestThread has been made more robust (in the style of
salhelper::Thread) to avoid races.

Change-Id: I2cbd1b3f9aecc1bf4649e482d2c22b33b471788f
2012-05-23 10:10:51 +02:00
Michael Stahl
5729da18a1 fdo#42865: privatized unique empty string symbol:
Unfortunately this --enable-dbg-util only problem (caused by
_GLIBCXX_DEUBG) resurfaced, perhaps because of new std::string based
logging in sal; adapt all map files to export the unique symbol.
2012-05-18 16:33:19 +02:00
Stephan Bergmann
d015384e1d Fixed ThreadPool (and dependent ORequestThread) life cycle
At least with sw_complex test under load, it happened that an ORequestThread
could still process a remote release request while the main thread was already
in exit(3).  This was because (a) ThreadPool never joined with the spawned
worker threads (which has been rectified by calling uno_threadpool_dispose(0)
from the final uno_threadpool_destroy), and (b) binaryurp::Bridge called
uno_threadpool_destroy only from its destructor (which could go as late as
exit(3)) instead of from terminate.

Additional clean up:
* Access to Bridge's threadPool_ is now cleanly controlled by mutex_ (even
  though that might not be necessary in every case).
* ThreadPool's stopDisposing got renamed to destroy, to make meaning clearer.

Change-Id: I45fa76e80e790a11065e7bf8ac9d92af2e62f262
2012-05-16 22:09:21 +02:00
Bjoern Michaelsen
b1c3e8ae28 make gbuild the default assumption of build.pl
this removes dmake completely out of the build for migrated modules
build.pl now assumes modules to be gbuild, unless there is a
prj/dmake file

Change-Id: I674a036b182ee13c5ec093e83cb3d38133112d3b
2012-04-29 03:50:46 +02:00
Caolán McNamara
df6d495f2a fix OSL_DEBUG_LEVEL > 1 build 2012-04-26 11:41:59 +01:00
Stephan Bergmann
61a8905c48 Reverted "Leak TypeDescriptor_Init_Impl to avoid problems at exit."
(This reverts commit 0ba6bd3ddc025666a6d4bb0640bf443728b23bd3.)

The problems worked-around there are no longer observed by me, so they
were hopefully only a temporal problem (the real root cause had never
been found back then).  If problems start to pop up again, we'll need
to have another look at this.
2012-04-26 09:33:12 +02:00
Catalin Iacob
fd0790a219 WaE: Clang unused variable 2012-04-25 10:07:00 +02:00
Tor Lillqvist
0d0b7947aa WaE: implicit conversion changes signedness 2012-04-24 12:22:58 +03:00
Luboš Luňák
8d1fbba77f doxygen warning fixes 2012-04-23 19:17:42 +02:00
Norbert Thiebaud
aa28e0e3d4 remove doxygen warnings 2012-04-17 22:10:10 -05:00
Matúš Kukan
9e7d5cd530 cppu: use InternalUnoApi 2012-04-09 21:04:37 +02:00
Michael Stahl
4c50f23f87 LinkTarget.mk: remove gb_LinkTarget_add_package_headers 2012-04-08 01:05:53 +02:00
Michael Stahl
c923f7d2c2 gbuild: "use" vs. "add":
Naming convention for gbuild methods:
- "add" is used for stuff that is logically a part of the target
  (i.e. not registered at the Module, but defined in the target's makefile)
- "use" is used for stuff that is logically a different target
  (i.e. it is registered at the Module, has it's own makefile, may be
  in a different module than the target)
2012-04-08 01:05:52 +02:00
Szabolcs Dezsi
d6bc02f8c4 Replaced equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(...)) with == operator 2012-04-06 20:03:42 +02:00
Szabolcs Dezsi
743f22045c Replaced equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(...)) with == operator
Pattern used:

find . -name "*.cxx" -exec sed -i 's/\( *\)\(else if\|if\) *( *\([^!()|&]*\)\.equalsAsciiL( *RTL_CONSTASCII_STRINGPARAM *( *\([^)]*\)) *) *)$/\1\2 ( \3 == \4 )/' \{\} \;
2012-04-06 15:07:41 +02:00
Tor Lillqvist
694bb9f5de Do two fairly useless but often emitted OSL_TRACEs only if OSL_DEBUG_LEVEL > 2 2012-04-05 20:46:26 +03:00
Tor Lillqvist
128749140f More hacking on static linking (iOS) support 2012-03-21 00:00:05 +02:00
Tor Lillqvist
c0ab229dc7 Uniquify uno_initEnvironment and uno_ext_getMapping in the static linking case 2012-03-21 00:00:04 +02:00
Tor Lillqvist
a8f19ca300 Use MAX_ALIGNMENT_4 also for iOS 2012-03-21 00:00:02 +02:00
Stephan Bergmann
ba6714d34f Dead code 2012-03-14 15:23:22 +01:00
Stephan Bergmann
6e67c03dc0 Enable -Wnon-virtual-dtor for GCC 4.6
...which has the necessary features to support it.

Change a lot of classes to either contain a protected non-virtual dtor
(which is backwards compatible, so even works for cppumaker-generated
UNO headers) or a public virtual one.

cppuhelper/propertysetmixin.hxx still needs to disable the warning, as
the relevant class has a non-virtual dtor but friends, which would still
cause GCC to warn.

Includes a patch for libcmis, intended to be upstreamed.
2012-03-14 13:32:02 +01:00
Matúš Kukan
84b3f7b345 gbuild: get rid of realpath in gb_Foo_set_include 2012-03-10 21:23:20 +01:00
Michael Stahl
a860cd108c cppu: JobQueue::enter: add mutex guards for m_nToDo
Considered replacing it with oslInterlockedCount, but wondered why there is
no osl_getInterlockedCount (similar to glib's g_atomic_int_get)...
2012-02-27 20:53:20 +01:00
Korrawit Pruegsanusak
98a11f3ad9 Some doxygen warnings cleanup 2012-02-23 22:58:06 +07:00
Thomas Arnhold
b1073d9fa2 WaE: silence some documentation errors 2012-02-21 23:16:31 +01:00
Michael Meeks
3e41d0bf6a cleanup: remove remenants of gcc version checking 2012-02-14 14:15:52 +00:00
Stephan Bergmann
cba3ac1eab Avoid deadlocks when disposing recursive JobQueue::enter
...where the outer JobQueue::enter blocks on m_cndWait after it has been reset
again due to m_lstJob.empty().
2012-02-10 16:26:00 +01:00
Josh Heidenreich
fb78dbcdc5 Added READMEs for modules related to URE, with content from the wiki 2012-02-06 05:28:46 +01:00
Norbert Thiebaud
c857dff7fc switch to include-based build rather than sourced-based build 2012-02-05 19:34:05 -06:00
Alexander Bergmann
0439af27e1 Code cleanup: ( () ) replaced by (()) 2012-01-26 17:41:07 +00:00
Stephan Bergmann
7c704c78d3 Removed some unused parameters; added SAL_UNUSED_PARAMETER.
SAL_UNUSED_PARAMETER (expanding to __attribute__ ((unused)) for GCC)
is used to annotate legitimately unused parameters, so that static
analysis tools can tell legitimately unused parameters from truly
unnecessary ones.  To that end, some patches for external modules
are also added, that are only applied when compiling with GCC and
add necessary __attribute__ ((unused)) in headers.
2012-01-21 15:21:16 +01:00
Stephan Bergmann
3c7ad92d43 Drop UNO_REF_QUERY[_THROW] duplicates of UNO_QUERY[_THROW].
They are virtually unused (at least the LibO code base has only a
single use of UNO_REF_QUERY) but confuse static analysis tools that
classify unused function parameters as "tags" (which legalizes the
unusedness of those parameters) if they are of an enum type with
exactly one value defined.
2012-01-19 20:54:35 +01:00
Caolán McNamara
504e01e52e typo in OSL_DEBUG_LEVEL > 1 code 2012-01-06 09:52:42 +00:00
Stephan Bergmann
58ab12acf5 Switch from autodoc to doxygen for SDK C++ documentation.
* New build prerequisite doxygen (controllable via --with-doxygen).
* Adapted various headers to slightly different doxygen documentation
  syntax, but much clean up still remains to be done (i.e., warnings
  emitted by doxygen fixed).
2012-01-05 19:43:14 +01:00
Stephan Bergmann
0ba6bd3ddc Leak TypeDescriptor_Init_Impl to avoid problems at exit. 2012-01-05 11:58:40 +01:00
Stephan Bergmann
321894af2c Explicitly initialize TypeDescriptor_Init_Impl. 2012-01-05 11:54:08 +01:00
Stephan Bergmann
9d54084d61 Replace dynamic array with std::vector. 2012-01-02 18:01:42 +01:00