diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2013-04-17 16:43:13 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2013-04-22 18:25:42 +0200 |
commit | 5275ed805a6e42f56c59d1c5876a7994625905a9 (patch) | |
tree | 0a802c2ce8bbf54c047ada5c303a403b51ba8136 /unoidl | |
parent | f21d1faf6d5a8d9df84b48becbc137175d56ad79 (diff) |
Revert "Revert "WIP: Experimental new binary type.rdb format""
This reverts commit 67e69a55820f50973ca0de75ccab2bb07d0bada8, applying a band-
aid fix to cli_ure/source/climaker for now.
Conflicts:
stoc/inc/bootstrapservices.hxx
stoc/source/tdmanager/lrucache.hxx
stoc/source/tdmanager/tdmgr.cxx
stoc/source/tdmanager/tdmgr_common.hxx
stoc/source/tdmanager/tdmgr_tdenumeration.cxx
stoc/source/tdmanager/tdmgr_tdenumeration.hxx
Change-Id: Iae669985d0194f06fa349a4a39f0ebd230bc5d28
Diffstat (limited to 'unoidl')
-rw-r--r-- | unoidl/inc/unoidl/unoidl.hxx | 2 | ||||
-rw-r--r-- | unoidl/source/unoidl.cxx | 5 |
2 files changed, 6 insertions, 1 deletions
diff --git a/unoidl/inc/unoidl/unoidl.hxx b/unoidl/inc/unoidl/unoidl.hxx index 02435316cb58..9d774473c7ee 100644 --- a/unoidl/inc/unoidl/unoidl.hxx +++ b/unoidl/inc/unoidl/unoidl.hxx @@ -15,6 +15,7 @@ #include <cassert> #include <vector> +#include "osl/mutex.hxx" #include "rtl/ref.hxx" #include "rtl/ustring.hxx" #include "sal/types.h" @@ -626,6 +627,7 @@ public: private: virtual SAL_DLLPRIVATE ~Manager() throw (); + mutable osl::Mutex mutex_; std::vector< rtl::Reference< Provider > > providers_; }; diff --git a/unoidl/source/unoidl.cxx b/unoidl/source/unoidl.cxx index 2b92afd50b31..a9939e4b9755 100644 --- a/unoidl/source/unoidl.cxx +++ b/unoidl/source/unoidl.cxx @@ -12,6 +12,7 @@ #include <set> #include <vector> +#include "osl/mutex.hxx" #include "rtl/ref.hxx" #include "rtl/ustring.hxx" #include "unoidl/legacyprovider.hxx" @@ -116,11 +117,13 @@ rtl::Reference< Provider > loadProvider( void Manager::addProvider(rtl::Reference< Provider > const & provider) { assert(provider.is()); + osl::MutexGuard g(mutex_); providers_.push_back(provider); } rtl::Reference< Entity > Manager::findEntity(rtl::OUString const & name) const { - //TODO: add caching + //TODO: caching? (here or in cppuhelper::TypeManager?) + osl::MutexGuard g(mutex_); for (std::vector< rtl::Reference< Provider > >::const_iterator i( providers_.begin()); i != providers_.end(); ++i) |