summaryrefslogtreecommitdiff
path: root/xmloff/source/table/XMLTableImport.cxx
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2017-09-21 12:12:33 +0100
committerCaolán McNamara <caolanm@redhat.com>2017-09-22 11:01:53 +0200
commit442df6cf8345f8029d5a3b470bc4981a5aa2bf20 (patch)
tree9efa6f2b29f41d79f968d1e8ad2588c323305776 /xmloff/source/table/XMLTableImport.cxx
parenta411d7729ab2bed05c3c5d22a8cbcf5dde034b91 (diff)
ofz: don't leak in face of exceptions
Change-Id: Ic15590a13bd3770ee5dd7db76b21c830a4fe73e2 Reviewed-on: https://gerrit.libreoffice.org/42587 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'xmloff/source/table/XMLTableImport.cxx')
-rw-r--r--xmloff/source/table/XMLTableImport.cxx24
1 files changed, 12 insertions, 12 deletions
diff --git a/xmloff/source/table/XMLTableImport.cxx b/xmloff/source/table/XMLTableImport.cxx
index 9042de6b1450..031af1e40188 100644
--- a/xmloff/source/table/XMLTableImport.cxx
+++ b/xmloff/source/table/XMLTableImport.cxx
@@ -70,7 +70,7 @@ class XMLProxyContext : public SvXMLImportContext
public:
XMLProxyContext( SvXMLImport& rImport, const SvXMLImportContextRef& xParent, sal_uInt16 nPrfx, const OUString& rLName );
- virtual SvXMLImportContext *CreateChildContext( sal_uInt16 nPrefix, const OUString& rLocalName, const Reference< XAttributeList >& xAttrList ) override;
+ virtual SvXMLImportContextRef CreateChildContext( sal_uInt16 nPrefix, const OUString& rLocalName, const Reference< XAttributeList >& xAttrList ) override;
private:
SvXMLImportContextRef mxParent;
@@ -94,7 +94,7 @@ class XMLTableImportContext : public SvXMLImportContext
public:
XMLTableImportContext( const rtl::Reference< XMLTableImport >& xThis, sal_uInt16 nPrfx, const OUString& rLName, Reference< XColumnRowRange > const & xColumnRowRange );
- virtual SvXMLImportContext *CreateChildContext( sal_uInt16 nPrefix, const OUString& rLocalName, const Reference< XAttributeList >& xAttrList ) override;
+ virtual SvXMLImportContextRef CreateChildContext( sal_uInt16 nPrefix, const OUString& rLocalName, const Reference< XAttributeList >& xAttrList ) override;
virtual void StartElement( const Reference< XAttributeList >& xAttrList ) override;
@@ -102,9 +102,9 @@ public:
void InitColumns();
- SvXMLImportContext * ImportColumn( sal_uInt16 nPrefix, const OUString& rLocalName, const Reference< XAttributeList >& xAttrList );
+ SvXMLImportContextRef ImportColumn( sal_uInt16 nPrefix, const OUString& rLocalName, const Reference< XAttributeList >& xAttrList );
SvXMLImportContext * ImportRow( sal_uInt16 nPrefix, const OUString& rLocalName, const Reference< XAttributeList >& xAttrList );
- SvXMLImportContext * ImportCell( sal_uInt16 nPrefix, const OUString& rLocalName, const Reference< XAttributeList >& xAttrList );
+ SvXMLImportContextRef ImportCell( sal_uInt16 nPrefix, const OUString& rLocalName, const Reference< XAttributeList >& xAttrList );
OUString GetDefaultCellStyleName() const;
@@ -131,7 +131,7 @@ public:
sal_uInt16 nPrfx, const OUString& rLName,
const css::uno::Reference< css::xml::sax::XAttributeList >& xAttrList );
- virtual SvXMLImportContext *CreateChildContext( sal_uInt16 nPrefix, const OUString& rLocalName, const Reference< XAttributeList >& xAttrList ) override;
+ virtual SvXMLImportContextRef CreateChildContext( sal_uInt16 nPrefix, const OUString& rLocalName, const Reference< XAttributeList >& xAttrList ) override;
virtual void EndElement() override;
@@ -152,7 +152,7 @@ class XMLTableTemplateContext : public SvXMLStyleContext
public:
XMLTableTemplateContext( SvXMLImport& rImport, sal_uInt16 nPrfx, const OUString& rLName, const Reference< XAttributeList >& xAttrList );
- virtual SvXMLImportContext *CreateChildContext( sal_uInt16 nPrefix, const OUString& rLocalName, const Reference< XAttributeList >& xAttrList ) override;
+ virtual SvXMLImportContextRef CreateChildContext( sal_uInt16 nPrefix, const OUString& rLocalName, const Reference< XAttributeList >& xAttrList ) override;
virtual void StartElement( const Reference< XAttributeList >& xAttrList ) override;
@@ -172,7 +172,7 @@ XMLProxyContext::XMLProxyContext( SvXMLImport& rImport, const SvXMLImportContext
{
}
-SvXMLImportContext * XMLProxyContext::CreateChildContext( sal_uInt16 nPrefix, const OUString& rLocalName, const Reference< XAttributeList >& xAttrList )
+SvXMLImportContextRef XMLProxyContext::CreateChildContext( sal_uInt16 nPrefix, const OUString& rLocalName, const Reference< XAttributeList >& xAttrList )
{
if( mxParent.is() )
return mxParent->CreateChildContext( nPrefix, rLocalName, xAttrList );
@@ -372,7 +372,7 @@ XMLTableImportContext::XMLTableImportContext( const rtl::Reference< XMLTableImpo
{
}
-SvXMLImportContext * XMLTableImportContext::ImportColumn( sal_uInt16 nPrefix, const OUString& rLocalName, const Reference< XAttributeList >& xAttrList )
+SvXMLImportContextRef XMLTableImportContext::ImportColumn( sal_uInt16 nPrefix, const OUString& rLocalName, const Reference< XAttributeList >& xAttrList )
{
if( mxColumns.is() && (mnCurrentRow == -1) ) try
{
@@ -534,7 +534,7 @@ SvXMLImportContext * XMLTableImportContext::ImportRow( sal_uInt16 nPrefix, const
return new XMLProxyContext( GetImport(), xThis, nPrefix, rLocalName );
}
-SvXMLImportContext * XMLTableImportContext::ImportCell( sal_uInt16 nPrefix, const OUString& rLocalName, const Reference< XAttributeList >& xAttrList )
+SvXMLImportContextRef XMLTableImportContext::ImportCell( sal_uInt16 nPrefix, const OUString& rLocalName, const Reference< XAttributeList >& xAttrList )
{
mnCurrentColumn++;
if( mxColumns.is() ) try
@@ -567,7 +567,7 @@ SvXMLImportContext * XMLTableImportContext::ImportCell( sal_uInt16 nPrefix, cons
return SvXMLImportContext::CreateChildContext( nPrefix, rLocalName, xAttrList);
}
-SvXMLImportContext *XMLTableImportContext::CreateChildContext( sal_uInt16 nPrefix, const OUString& rLocalName, const Reference< XAttributeList >& xAttrList )
+SvXMLImportContextRef XMLTableImportContext::CreateChildContext( sal_uInt16 nPrefix, const OUString& rLocalName, const Reference< XAttributeList >& xAttrList )
{
if( nPrefix == XML_NAMESPACE_TABLE )
{
@@ -696,7 +696,7 @@ XMLCellImportContext::XMLCellImportContext( SvXMLImport& rImport, const Referenc
}
}
-SvXMLImportContext * XMLCellImportContext::CreateChildContext( sal_uInt16 nPrefix, const OUString& rLocalName, const Reference< XAttributeList >& xAttrList )
+SvXMLImportContextRef XMLCellImportContext::CreateChildContext( sal_uInt16 nPrefix, const OUString& rLocalName, const Reference< XAttributeList >& xAttrList )
{
// create text cursor on demand
if( !mxCursor.is() )
@@ -791,7 +791,7 @@ void XMLTableTemplateContext::CreateAndInsert(bool bOverwrite)
xTableImport->insertTabletemplate(msTemplateStyleName, bOverwrite);
}
-SvXMLImportContext * XMLTableTemplateContext::CreateChildContext( sal_uInt16 nPrefix, const OUString& rLocalName, const Reference< XAttributeList >& xAttrList )
+SvXMLImportContextRef XMLTableTemplateContext::CreateChildContext( sal_uInt16 nPrefix, const OUString& rLocalName, const Reference< XAttributeList >& xAttrList )
{
if( nPrefix == XML_NAMESPACE_TABLE )
{