summaryrefslogtreecommitdiff
path: root/cppu/source/threadpool/thread.cxx
AgeCommit message (Collapse)AuthorFilesLines
2014-11-14cid#983623 Don't throw DisposedException past uno_threadpool_putJobStephan Bergmann1-12/+8
This improves on b68640c44ecdb1df59d704cc6c2bae8bb412d7d0 "Prevent creation of new ORequestThreads during shutdown," which added throwing the DisposedException from ThreadAdmin::add. But ThreadAdmin::m_disposed can only become true via uno_threadpool_destroy -> ThreadPool::joinWorkers -> ThreadAdmin::join, and ThreadAdmin::add observing that can only happen via uno_threadpool_putJob -> ThreadPool::addJob -> ThreadPool::createThread -> ORequestThread::launch -> ThradAdmin::add, where the bridges should ensure that uno_threadpool_destroy does not run in parallel with uno_threadpool_putJob. So demote this from a DisposedException to a SAL_WARN. Change-Id: I3912ea077b7fa35827c41e82dd0a8f962ba412b6
2014-08-25set names on a bunch more threads...Michael Stahl1-0/+2
Change-Id: I4c2f2f0bcce52839033876ec991529721e06a3c8
2014-05-23remove boilerplate in UNO Exception constructor callsNoel Grandin1-3/+1
Now that we have default values for Exception constructor params, remove lots of boilerplate code. Change-Id: I620bd641eecfed38e6123873b3b94aaf47922e74
2014-05-19oox: drop using from headerThomas Arnhold1-0/+1
Change-Id: Ie353c561ccdcfb3c198ff05943f0ea64a3626735
2014-02-23Remove unneccessary commentsAlexander Wilms1-2/+2
Change-Id: I939160ae72fecbe3d4a60ce755730bd4c38497fb Reviewed-on: https://gerrit.libreoffice.org/8182 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2014-02-17cppu: sal_Bool -> boolStephan Bergmann1-3/+3
Change-Id: I1288f1f6f38d1475b4eb5272509e479bd9f2552d
2013-05-06remove usage of RTL_CONSTASCII_USTRINGPARAMLuboš Luňák1-2/+1
Mechanical removal of usage together with OUString ctor, done by compiler plugin. Change-Id: I554227f76df0dac620b1b46fca32516f78b462c5
2012-11-30c++ API: use css alias in generated headers, adds global css declThorsten Behrens1-6/+0
This changes all generated API headers (.hpp and .hdl) to use a namespace alias 'css' instead of the pointlessly long com::sun::star Makes the change in cppumaker & associated tools, adds a global namespace alias definition in sal/types.h, and removes a kiloton of local, now pointless-to-harmful versions of that alias from all over the code. Change-Id: Ice5a644a6b971a981f01dc0589d48f5add31cc0f
2012-06-13re-base on ALv2 code.Michael Meeks1-23/+14
2012-05-23Better fix for ThreadPool/ORequestThread life cycleStephan Bergmann1-105/+79
This is a follow up to d015384e1d98fe77fd59339044f58efb1ab9fb25 "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
2011-12-19Prevent creation of new ORequestThreads during shutdown.Stephan Bergmann1-0/+25
2011-11-27remove include of pch header in cppuNorbert Thiebaud1-2/+0
2010-10-14Add vim/emacs modelines to all source filesSebastian Spaeth1-0/+3
Fixes #fdo30794 Based on bin/add-modelines script (originally posted in mail 1286706307.1871.1399280959@webmail.messagingengine.com) Signed-off-by: Sebastian Spaeth <Sebastian@SSpaeth.de>
2010-10-11#i107490# cppu lifecycle cleanupCaolán McNamara1-15/+17
2010-02-12changefileheader2: #i109125#: change source file copyright notice from Sun ↵Jens-Heiner Rechtien1-4/+1
Microsystems to Oracle; remove CVS style keywords (RCSfile, Revision)
2008-04-11INTEGRATION: CWS changefileheader (1.12.34); FILE MERGEDRüdiger Timm1-23/+18
2008/03/31 07:23:20 rt 1.12.34.1: #i87441# Change license header to LPGL v3.
2007-07-18INTEGRATION: CWS unomacli64 (1.11.36); FILE MERGEDOliver Bolte1-3/+3
2007/06/07 10:54:33 kr 1.11.36.2: fixed: #i77600# warning because of wrong format specifier - now uses C++ style casts 2007/06/07 09:22:29 kr 1.11.36.1: fixed: #i77600# warning because of wrong format specifier
2006-09-16INTEGRATION: CWS pchfix02 (1.10.10); FILE MERGEDOliver Bolte1-2/+5
2006/09/01 17:23:01 kaib 1.10.10.1: #i68856# Added header markers and pch files
2006-06-19INTEGRATION: CWS warnings01 (1.6.46); FILE MERGEDJens-Heiner Rechtien1-5/+10
2005/09/22 20:43:02 sb 1.6.46.3: RESYNC: (1.6-1.7); FILE MERGED 2005/09/06 10:11:50 sb 1.6.46.2: #i53898# sal::reinterpret_int_cast is not needed. 2005/08/29 14:03:50 sb 1.6.46.1: #i53898# Made code warning-free.
2006-04-26INTEGRATION: CWS jsc9 (1.8.2); FILE MERGEDKurt Zenker1-13/+8
2006/04/26 14:15:33 jsc 1.8.2.1: #134738# move fixes back to previous version
2006-04-19INTEGRATION: CWS sb49 (1.7.38); FILE MERGEDJens-Heiner Rechtien1-8/+13
2006/03/22 10:14:05 sb 1.7.38.1: #i63397# Keep objects alive long enough so that threads still running while atexit handlers are processed do not access dead objects.
2005-09-08INTEGRATION: CWS ooo19126 (1.6.50); FILE MERGEDRüdiger Timm1-47/+21
2005/09/05 13:54:26 rt 1.6.50.1: #i54170# Change license header: remove SISSL
2004-04-21INTEGRATION: CWS ooo20040329 (1.5.70); FILE MERGEDSander Vesik1-5/+6
2004/03/15 12:56:57 waratah 1.5.70.1: #i1858# correct some ordering on the class definition to stop some warnings under -Wall Break apart an assignment from an if statement to remove another warning
2003-04-15INTEGRATION: CWS dbgmacros1 (1.4.58); FILE MERGEDVladimir Glazounov1-3/+3
2003/04/09 10:38:50 kso 1.4.58.1: #108413# - debug macro unification.
2001-06-08#87994# osl_freeThreadHandle() is replaced by osl_destroyThreadJörg Budischewski1-3/+3
2001-02-20#83737# uno_threadpool_disposeThreads now offers a feature to join on all ↵Jörg Budischewski1-4/+80
previously created threads (when the method is called with a 0 as bridgeID)
2000-09-29temporary hack for thread local storage removedJörg Budischewski1-6/+2
2000-09-18initial importJens-Heiner Rechtien1-0/+170