summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorXisco Fauli <anistenis@gmail.com>2016-06-01 01:21:36 +0200
committerNoel Grandin <noelgrandin@gmail.com>2016-06-03 06:49:46 +0000
commit2d2971090b31776719e83d811c17a01aaf5222c7 (patch)
treeeaf4f307ca2d1b0ee740b5844f4192dae8a55a3b
parent9196de99ed4dff2c1f8708bfd68da9b6424ae53b (diff)
tdf#89329: use unique_ptr for pImpl in accimplaccess
Change-Id: Ib10088b5669695dd5e288fe043ad72056a34b1e4 Reviewed-on: https://gerrit.libreoffice.org/25745 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
-rw-r--r--comphelper/source/misc/accimplaccess.cxx3
-rw-r--r--include/comphelper/accimplaccess.hxx3
2 files changed, 3 insertions, 3 deletions
diff --git a/comphelper/source/misc/accimplaccess.cxx b/comphelper/source/misc/accimplaccess.cxx
index 76ed77c0ee9d..1c4096f38e08 100644
--- a/comphelper/source/misc/accimplaccess.cxx
+++ b/comphelper/source/misc/accimplaccess.cxx
@@ -24,6 +24,7 @@
#include <set>
#include <string.h>
+#include <memory>
namespace comphelper
@@ -49,8 +50,6 @@ namespace comphelper
OAccessibleImplementationAccess::~OAccessibleImplementationAccess( )
{
- delete m_pImpl;
- m_pImpl = nullptr;
}
diff --git a/include/comphelper/accimplaccess.hxx b/include/comphelper/accimplaccess.hxx
index ab960ddfab2c..5c048da5c186 100644
--- a/include/comphelper/accimplaccess.hxx
+++ b/include/comphelper/accimplaccess.hxx
@@ -23,6 +23,7 @@
#include <cppuhelper/implbase1.hxx>
#include <com/sun/star/lang/XUnoTunnel.hpp>
#include <comphelper/comphelperdllapi.h>
+#include <memory>
namespace com { namespace sun { namespace star { namespace accessibility {
class XAccessible;
@@ -62,7 +63,7 @@ namespace comphelper
class COMPHELPER_DLLPUBLIC OAccessibleImplementationAccess : public OAccImpl_Base
{
private:
- OAccImpl_Impl* m_pImpl;
+ std::unique_ptr<OAccImpl_Impl> m_pImpl;
protected:
/// retrieves the parent previously set via <method>setAccessibleParent</method>