diff options
author | Caolán McNamara <caolanm@redhat.com> | 2022-01-20 09:23:01 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2022-01-20 11:59:39 +0100 |
commit | 1284937bf2bd112197a99e844a5a1a961e2cf4fc (patch) | |
tree | 3501a3a6eea332d87ddc0acc43262b0c3e0a425d /lotuswordpro | |
parent | 7b37a1a5144a3a4c8b0803b7e2da81e9e108bf66 (diff) |
ofz#43689 Direct-Leak
Change-Id: I09823f30817163b0467b6b96f56956987337b991
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128646
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'lotuswordpro')
-rw-r--r-- | lotuswordpro/source/filter/lwpsdwgrouploaderv0102.cxx | 8 | ||||
-rw-r--r-- | lotuswordpro/source/filter/lwpsdwgrouploaderv0102.hxx | 2 |
2 files changed, 5 insertions, 5 deletions
diff --git a/lotuswordpro/source/filter/lwpsdwgrouploaderv0102.cxx b/lotuswordpro/source/filter/lwpsdwgrouploaderv0102.cxx index 47362c809892..916531a8d624 100644 --- a/lotuswordpro/source/filter/lwpsdwgrouploaderv0102.cxx +++ b/lotuswordpro/source/filter/lwpsdwgrouploaderv0102.cxx @@ -234,7 +234,7 @@ void LwpSdwGroupLoaderV0102::BeginDrawObjects(std::vector< rtl::Reference<XFFram * the corresponding drawing objects. * @param pDrawObjVector a container which will contains the created drawing object of XF-Model. */ -XFDrawGroup* LwpSdwGroupLoaderV0102::CreateDrawGroupObject() +rtl::Reference<XFDrawGroup> LwpSdwGroupLoaderV0102::CreateDrawGroupObject() { //flag unsigned char BinSignature[2]; @@ -263,7 +263,7 @@ XFDrawGroup* LwpSdwGroupLoaderV0102::CreateDrawGroupObject() // fileSize m_pStream->SeekRel(2); - XFDrawGroup* pXFDrawGroup = new XFDrawGroup(); + rtl::Reference<XFDrawGroup> xXFDrawGroup(new XFDrawGroup()); if (nRecCount > m_pStream->remainingSize()) { @@ -284,12 +284,12 @@ XFDrawGroup* LwpSdwGroupLoaderV0102::CreateDrawGroupObject() } else { - pXFDrawGroup->Add(xXFDrawObj.get()); + xXFDrawGroup->Add(xXFDrawObj.get()); } } } - return pXFDrawGroup; + return xXFDrawGroup; } /** diff --git a/lotuswordpro/source/filter/lwpsdwgrouploaderv0102.hxx b/lotuswordpro/source/filter/lwpsdwgrouploaderv0102.hxx index b0e5b21072bb..d9d63e8424b3 100644 --- a/lotuswordpro/source/filter/lwpsdwgrouploaderv0102.hxx +++ b/lotuswordpro/source/filter/lwpsdwgrouploaderv0102.hxx @@ -83,7 +83,7 @@ public: public: void BeginDrawObjects(std::vector<rtl::Reference<XFFrame>>* pDrawObjVector); - XFDrawGroup* CreateDrawGroupObject(); + rtl::Reference<XFDrawGroup> CreateDrawGroupObject(); rtl::Reference<XFFrame> CreateDrawObject(); }; |