cppcheck:useInitializationList
Change-Id: I744ff3e268fbffca9499121f3567640934aaae51 Reviewed-on: https://gerrit.libreoffice.org/20110 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
This commit is contained in:
@@ -1303,9 +1303,8 @@ css::uno::Reference< css::uno::XInterface > Access::createInstanceWithArguments(
|
||||
}
|
||||
|
||||
Access::Access(Components & components):
|
||||
components_(components), disposed_(false)
|
||||
components_(components), disposed_(false), lock_( lock() )
|
||||
{
|
||||
lock_ = lock();
|
||||
}
|
||||
|
||||
Access::~Access() {}
|
||||
|
||||
@@ -76,18 +76,18 @@ ChildAccess::ChildAccess(
|
||||
rtl::Reference< Access > const & parent, OUString const & name,
|
||||
rtl::Reference< Node > const & node):
|
||||
Access(components), root_(root), parent_(parent), name_(name), node_(node),
|
||||
inTransaction_(false)
|
||||
inTransaction_(false),
|
||||
lock_( lock() )
|
||||
{
|
||||
lock_ = lock();
|
||||
assert(root.is() && parent.is() && node.is());
|
||||
}
|
||||
|
||||
ChildAccess::ChildAccess(
|
||||
Components & components, rtl::Reference< RootAccess > const & root,
|
||||
rtl::Reference< Node > const & node):
|
||||
Access(components), root_(root), node_(node), inTransaction_(false)
|
||||
Access(components), root_(root), node_(node), inTransaction_(false),
|
||||
lock_( lock() )
|
||||
{
|
||||
lock_ = lock();
|
||||
assert(root.is() && node.is());
|
||||
}
|
||||
|
||||
|
||||
@@ -170,9 +170,9 @@ Components::WriteThread::WriteThread(
|
||||
rtl::Reference< WriteThread > * reference, Components & components,
|
||||
OUString const & url, Data const & data):
|
||||
Thread("configmgrWriter"), reference_(reference), components_(components),
|
||||
url_(url), data_(data)
|
||||
url_(url), data_(data),
|
||||
lock_( lock() )
|
||||
{
|
||||
lock_ = lock();
|
||||
assert(reference != nullptr);
|
||||
}
|
||||
|
||||
|
||||
@@ -93,9 +93,9 @@ class Service:
|
||||
public:
|
||||
explicit Service(
|
||||
css::uno::Reference< css::uno::XComponentContext > const context):
|
||||
ServiceBase(m_aMutex), context_(context), default_(true)
|
||||
ServiceBase(m_aMutex), context_(context), default_(true),
|
||||
lock_( lock() )
|
||||
{
|
||||
lock_ = lock();
|
||||
assert(context.is());
|
||||
}
|
||||
|
||||
@@ -103,9 +103,9 @@ public:
|
||||
css::uno::Reference< css::uno::XComponentContext > const context,
|
||||
OUString const & locale):
|
||||
ServiceBase(m_aMutex), context_(context), locale_(locale),
|
||||
default_(false)
|
||||
default_(false),
|
||||
lock_( lock() )
|
||||
{
|
||||
lock_ = lock();
|
||||
assert(context.is());
|
||||
}
|
||||
|
||||
|
||||
@@ -61,9 +61,10 @@ RootAccess::RootAccess(
|
||||
Components & components, OUString const & pathRepresentation,
|
||||
OUString const & locale, bool update):
|
||||
Access(components), pathRepresentation_(pathRepresentation),
|
||||
locale_(locale), update_(update), finalized_(false), alive_(true)
|
||||
locale_(locale),
|
||||
lock_( lock() ),
|
||||
update_(update), finalized_(false), alive_(true)
|
||||
{
|
||||
lock_ = lock();
|
||||
}
|
||||
|
||||
Path RootAccess::getAbsolutePath() {
|
||||
|
||||
@@ -28,9 +28,9 @@ namespace cppu_threadpool {
|
||||
|
||||
JobQueue::JobQueue() :
|
||||
m_nToDo( 0 ),
|
||||
m_bSuspended( false )
|
||||
m_bSuspended( false ),
|
||||
m_DisposedCallerAdmin( DisposedCallerAdmin::getInstance() )
|
||||
{
|
||||
m_DisposedCallerAdmin = DisposedCallerAdmin::getInstance();
|
||||
}
|
||||
|
||||
void JobQueue::add( void *pThreadSpecificData, RequestFun * doRequest )
|
||||
|
||||
@@ -101,9 +101,9 @@ namespace cppu_threadpool
|
||||
|
||||
|
||||
|
||||
ThreadPool::ThreadPool()
|
||||
ThreadPool::ThreadPool() :
|
||||
m_DisposedCallerAdmin( DisposedCallerAdmin::getInstance() )
|
||||
{
|
||||
m_DisposedCallerAdmin = DisposedCallerAdmin::getInstance();
|
||||
}
|
||||
|
||||
ThreadPool::~ThreadPool()
|
||||
|
||||
@@ -434,11 +434,12 @@ static void lo_registerCallback (LibreOfficeKit* pThis,
|
||||
static char* lo_getFilterTypes(LibreOfficeKit* pThis);
|
||||
|
||||
LibLibreOffice_Impl::LibLibreOffice_Impl()
|
||||
: maThread(nullptr)
|
||||
: m_pOfficeClass( gOfficeClass.lock() )
|
||||
, maThread(nullptr)
|
||||
, mpCallback(nullptr)
|
||||
, mpCallbackData(nullptr)
|
||||
{
|
||||
if(!(m_pOfficeClass = gOfficeClass.lock())) {
|
||||
if(!m_pOfficeClass) {
|
||||
m_pOfficeClass.reset(new LibreOfficeKitClass);
|
||||
m_pOfficeClass->nSize = sizeof(LibreOfficeKitClass);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user