summaryrefslogtreecommitdiff
path: root/configmgr/source/components.hxx
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2010-11-25 20:36:03 +0000
committerCaolán McNamara <caolanm@redhat.com>2010-11-25 20:36:03 +0000
commit83ab35b7351ba42097efc9c2b04044038e50e4f7 (patch)
tree16d9cc994bb549167c182201897f142f53e25890 /configmgr/source/components.hxx
parentc5ca3f408ff0cd4796e74ad871171c5ba84fe406 (diff)
Resolves: fdo#31494# get ownership right
Ensure that the mutex lives as long as all its consumers. And avoid launching threads if they have no work to do.
Diffstat (limited to 'configmgr/source/components.hxx')
-rw-r--r--configmgr/source/components.hxx4
1 files changed, 4 insertions, 0 deletions
diff --git a/configmgr/source/components.hxx b/configmgr/source/components.hxx
index 2d0843b20870..e810c6aee2db 100644
--- a/configmgr/source/components.hxx
+++ b/configmgr/source/components.hxx
@@ -35,6 +35,7 @@
#include <set>
#include "boost/noncopyable.hpp"
+#include "boost/shared_ptr.hpp"
#include "com/sun/star/beans/Optional.hpp"
#include "com/sun/star/uno/Reference.hxx"
#include "rtl/ref.hxx"
@@ -95,6 +96,8 @@ public:
void writeModifications();
+ bool hasModifications() const;
+
void flushModifications();
// must be called with configmgr::lock unaquired; must be called before
// shutdown if writeModifications has ever been called (probably
@@ -174,6 +177,7 @@ private:
WeakRootSet roots_;
ExternalServices externalServices_;
rtl::Reference< WriteThread > writeThread_;
+ boost::shared_ptr<osl::Mutex> lock_;
};
}