diff options
author | Takeshi Abe <tabe@fixedpoint.jp> | 2014-08-25 10:22:59 +0900 |
---|---|---|
committer | Takeshi Abe <tabe@fixedpoint.jp> | 2014-08-25 10:27:10 +0900 |
commit | 32ce5ae15a8f156b4681c36d248b6731df3457c6 (patch) | |
tree | fba1a1f0e0300b8e4209d593e3cfc7062542a72a /desktop | |
parent | 49feed98a1efa5accb9da4ab280d7cd47dcb344a (diff) |
Avoid possible memory leaks in case of exceptions
Change-Id: Icc073be041ae0b0c690e869a0edaff3515d1d601
Diffstat (limited to 'desktop')
-rw-r--r-- | desktop/source/deployment/gui/dp_gui_dialog2.cxx | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/desktop/source/deployment/gui/dp_gui_dialog2.cxx b/desktop/source/deployment/gui/dp_gui_dialog2.cxx index 50c17bcfe029..385614056750 100644 --- a/desktop/source/deployment/gui/dp_gui_dialog2.cxx +++ b/desktop/source/deployment/gui/dp_gui_dialog2.cxx @@ -72,6 +72,7 @@ #include <map> #include <vector> +#include <boost/scoped_ptr.hpp> #include <boost/shared_ptr.hpp> using namespace ::com::sun::star; @@ -488,11 +489,9 @@ IMPL_LINK_NOARG(ExtBoxWithBtns_Impl, HandleOptionsBtn) if ( pFact ) { OUString sExtensionId = GetEntryData( nActive )->m_xPackage->getIdentifier().Value; - VclAbstractDialog* pDlg = pFact->CreateOptionsDialog( this, sExtensionId, OUString() ); + boost::scoped_ptr<VclAbstractDialog> pDlg(pFact->CreateOptionsDialog( this, sExtensionId, OUString() )); pDlg->Execute(); - - delete pDlg; } } |