[Libreoffice-commits] core.git: lingucomponent/source

Stephan Bergmann (via logerrit) logerrit at kemper.freedesktop.org
Wed Mar 3 07:48:26 UTC 2021


 lingucomponent/source/spellcheck/macosxspell/macspellimp.mm |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 670df8db5cbb2a9cac46a8602b95192a02fa3e2c
Author:     Stephan Bergmann <sbergman at redhat.com>
AuthorDate: Tue Mar 2 13:42:21 2021 +0100
Commit:     Stephan Bergmann <sbergman at redhat.com>
CommitDate: Wed Mar 3 08:47:37 2021 +0100

    loplugin:refcounting (macOS)
    
    Change-Id: Id68d9c9733738595aeb4bad24d77f77da2878e83
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111830
    Tested-by: Jenkins
    Reviewed-by: Stephan Bergmann <sbergman at redhat.com>

diff --git a/lingucomponent/source/spellcheck/macosxspell/macspellimp.mm b/lingucomponent/source/spellcheck/macosxspell/macspellimp.mm
index 74b365c71746..cba8dae08094 100644
--- a/lingucomponent/source/spellcheck/macosxspell/macspellimp.mm
+++ b/lingucomponent/source/spellcheck/macosxspell/macspellimp.mm
@@ -35,6 +35,7 @@
 #include <unotools/pathoptions.hxx>
 #include <unotools/useroptions.hxx>
 #include <osl/file.hxx>
+#include <rtl/ref.hxx>
 #include <rtl/ustrbuf.hxx>
 
 using namespace utl;
@@ -486,7 +487,7 @@ Reference< XSpellAlternatives >
     }
 
     // now return an empty alternative for no suggestions or the list of alternatives if some found
-    SpellAlternatives *pAlt = new SpellAlternatives;
+    rtl::Reference<SpellAlternatives> pAlt = new SpellAlternatives;
     pAlt->SetWordLanguage( rWord, nLang );
     pAlt->SetFailureType( SpellFailure::SPELLING_ERROR );
     pAlt->SetAlternatives( aStr );


More information about the Libreoffice-commits mailing list