Kaydet (Commit) 54dae860 authored tarafından Stephan Bergmann's avatar Stephan Bergmann

~OfficeIPCThread can only be reached with pGlobalOfficeIPCThread cleared

...as only one instance of OfficeIPCThread is ever created (in
OfficeIPCThread::EnableOfficeIPCThread), which is then either assigned to
pGlobalOfficeIPCThread (if this is the first soffice instance), or
pGlobalOfficeIPCThread is left unassigned and the OfficeIPCThread instance goes
out of scope at the end of EnableOfficeIPCThread (if another soffice instance is
already running).

So mpDispatchWatcher also does not need to be cleared here, as it is only ever
accessed through pGlobalOfficeIPCThread.  And thus, there is no longer a need to
lock GetMutex() here, either.

Change-Id: I56cffc43361d01d747084153f318b8488519cf9b
üst da966b5e
......@@ -653,11 +653,7 @@ OfficeIPCThread::OfficeIPCThread() :
OfficeIPCThread::~OfficeIPCThread()
{
::osl::ClearableMutexGuard aGuard( GetMutex() );
mpDispatchWatcher.clear();
maPipe.close();
pGlobalOfficeIPCThread.clear();
}
void OfficeIPCThread::SetReady()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment