diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2014-10-01 15:03:54 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2014-10-01 17:35:08 +0200 |
commit | 4281abdfa8a417f7ba47c466410e1cbfed4342e0 (patch) | |
tree | e63ad9c555ef59f0c4d46a4b394d8c27ce6b70ef /sd/inc/sdmod.hxx | |
parent | 2d1e026e7a148761d30db77c57f36cceff3d327d (diff) |
sd: std::auto_ptr -> std::unique_ptr
ToolBarManager::Implementation::Update in sd/source/ui/view/ToolBarManager.cxx
is dubious. It takes its parameter by value (so in UnlockUpdate() the passed-in
mpSynchronousLayouterLock is reset upon passing it in), but the comment that it
"is [...] released at its end" together with the redundant
pLocalLayouterLock.reset() at the end of Update() make it look as though the
intention was to pass by reference. However, resetting
mpSynchronousLayouterLock even in the case where pass-by-ref would fail to reset
it is apparently important, as otherwise e.g. JunitTest_svx_unoapi would run
into the OSL_ASSERT(mpSynchronousLayouterLock.get()==NULL) in LockUpdate() with
a call stack of ... -> Update -> SetValid -> UpdateLockImplementation ->
LockUpdate.
Change-Id: I7d2717d5e1f8aa69c79a626c100d7fefb0cfb120
Diffstat (limited to 'sd/inc/sdmod.hxx')
-rw-r--r-- | sd/inc/sdmod.hxx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sd/inc/sdmod.hxx b/sd/inc/sdmod.hxx index d182a301bf6a..b1b42915500f 100644 --- a/sd/inc/sdmod.hxx +++ b/sd/inc/sdmod.hxx @@ -148,7 +148,7 @@ private: /** The resource container controls the lifetime of some singletons. */ - ::std::auto_ptr< ::sd::SdGlobalResourceContainer> mpResourceContainer; + ::std::unique_ptr< ::sd::SdGlobalResourceContainer> mpResourceContainer; /** Create a new summary page. When the document has been created in the kiosk mode with automatical transitions then this method adds |