sw/source/core/doc/DocumentStatisticsManager.cxx |    1 -
 sw/source/core/inc/DocumentStatisticsManager.hxx |    2 +-
 2 files changed, 1 insertion(+), 2 deletions(-)

New commits:
commit 2fc4af37bf321619cb6bd67cd051856301c7e074
Author: Noel Grandin <noel.gran...@collabora.co.uk>
Date:   Tue Apr 3 15:06:32 2018 +0200

    loplugin:useuniqueptr in DocumentStatisticsManager
    
    Change-Id: I71563287c05c0ffa9dc596b6f6e02431b13e693c
    Reviewed-on: https://gerrit.libreoffice.org/52346
    Tested-by: Jenkins <c...@libreoffice.org>
    Reviewed-by: Noel Grandin <noel.gran...@collabora.co.uk>

diff --git a/sw/source/core/doc/DocumentStatisticsManager.cxx 
b/sw/source/core/doc/DocumentStatisticsManager.cxx
index 135fcb50f782..0b8003283fb0 100644
--- a/sw/source/core/doc/DocumentStatisticsManager.cxx
+++ b/sw/source/core/doc/DocumentStatisticsManager.cxx
@@ -248,7 +248,6 @@ IMPL_LINK( DocumentStatisticsManager, DoIdleStatsUpdate, 
Timer *, pIdle, void )
 DocumentStatisticsManager::~DocumentStatisticsManager()
 {
     maStatsUpdateIdle.Stop();
-    delete mpDocStat;
 }
 
 }
diff --git a/sw/source/core/inc/DocumentStatisticsManager.hxx 
b/sw/source/core/inc/DocumentStatisticsManager.hxx
index 41b961f9cae5..6767d4b10cc5 100644
--- a/sw/source/core/inc/DocumentStatisticsManager.hxx
+++ b/sw/source/core/inc/DocumentStatisticsManager.hxx
@@ -60,7 +60,7 @@ private:
     // Our own 'StatsUpdateTimer' calls the following method
     DECL_LINK( DoIdleStatsUpdate, Timer *, void );
 
-    SwDocStat       *mpDocStat;          //< Statistics information
+    std::unique_ptr<SwDocStat> mpDocStat;//< Statistics information
     bool             mbInitialized;      //< allow first time update
     SwDocIdle        maStatsUpdateIdle;  //< Idle for asynchronous stats 
calculation
 };
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to