From 362d4f0cd4e50111edfae9d30c90602c37ed65a2 Mon Sep 17 00:00:00 2001 From: Stephan Bergmann Date: Tue, 1 Apr 2014 19:18:35 +0200 Subject: Explicitly mark overriding destructors as "virtual" It appears that the C++ standard allows overriding destructors to be marked "override," but at least some MSVC versions complain about it, so at least make sure such destructors are explicitly marked "virtual." Change-Id: I0e1cafa7584fd16ebdce61f569eae2373a71b0a1 --- include/comphelper/accessiblecomponenthelper.hxx | 2 +- include/comphelper/accessiblecontexthelper.hxx | 2 +- include/comphelper/accessiblewrapper.hxx | 6 +++--- include/comphelper/ihwrapnofilter.hxx | 2 +- include/comphelper/ofopxmlhelper.hxx | 2 +- include/comphelper/propagg.hxx | 2 +- include/comphelper/scoped_disposing_ptr.hxx | 2 +- include/comphelper/seqstream.hxx | 2 +- 8 files changed, 10 insertions(+), 10 deletions(-) (limited to 'include/comphelper') diff --git a/include/comphelper/accessiblecomponenthelper.hxx b/include/comphelper/accessiblecomponenthelper.hxx index c39b02486871..520ce81f71b8 100644 --- a/include/comphelper/accessiblecomponenthelper.hxx +++ b/include/comphelper/accessiblecomponenthelper.hxx @@ -43,7 +43,7 @@ namespace comphelper protected: /// see the respective base class ctor for an extensive comment on this, please OCommonAccessibleComponent( IMutex* _pExternalLock ); - ~OCommonAccessibleComponent(); + virtual ~OCommonAccessibleComponent(); protected: /// implements the calculation of the bounding rectangle - still waiting to be overwritten diff --git a/include/comphelper/accessiblecontexthelper.hxx b/include/comphelper/accessiblecontexthelper.hxx index fe2cdb5f7c08..a1a8247f09e6 100644 --- a/include/comphelper/accessiblecontexthelper.hxx +++ b/include/comphelper/accessiblecontexthelper.hxx @@ -90,7 +90,7 @@ namespace comphelper OContextHelper_Impl* m_pImpl; protected: - ~OAccessibleContextHelper( ); + virtual ~OAccessibleContextHelper( ); /** ctor diff --git a/include/comphelper/accessiblewrapper.hxx b/include/comphelper/accessiblewrapper.hxx index 3e7dab3f22af..26a81bfa167e 100644 --- a/include/comphelper/accessiblewrapper.hxx +++ b/include/comphelper/accessiblewrapper.hxx @@ -114,7 +114,7 @@ namespace comphelper ); protected: - ~OAccessibleWrapper( ); + virtual ~OAccessibleWrapper( ); private: COMPHELPER_DLLPRIVATE OAccessibleWrapper( ); // never implemented @@ -226,7 +226,7 @@ namespace comphelper virtual void notifyTranslatedEvent( const ::com::sun::star::accessibility::AccessibleEventObject& _rEvent ) throw (::com::sun::star::uno::RuntimeException) = 0; protected: - ~OAccessibleContextWrapperHelper( ); + virtual ~OAccessibleContextWrapperHelper( ); OAccessibleContextWrapperHelper( ); // never implemented OAccessibleContextWrapperHelper( const OAccessibleContextWrapperHelper& ); // never implemented @@ -397,7 +397,7 @@ namespace comphelper void implTranslateChildEventValue( const ::com::sun::star::uno::Any& _rInValue, ::com::sun::star::uno::Any& _rOutValue ); protected: - ~OWrappedAccessibleChildrenManager( ); + virtual ~OWrappedAccessibleChildrenManager( ); private: COMPHELPER_DLLPRIVATE OWrappedAccessibleChildrenManager( ); // never implemented diff --git a/include/comphelper/ihwrapnofilter.hxx b/include/comphelper/ihwrapnofilter.hxx index 0daa123428f3..f91595e21d4f 100644 --- a/include/comphelper/ihwrapnofilter.hxx +++ b/include/comphelper/ihwrapnofilter.hxx @@ -38,7 +38,7 @@ namespace comphelper { public: OIHWrapNoFilterDialog( com::sun::star::uno::Reference< com::sun::star::task::XInteractionHandler > xInteraction ); - ~OIHWrapNoFilterDialog(); + virtual ~OIHWrapNoFilterDialog(); static OUString SAL_CALL impl_staticGetImplementationName(); static ::com::sun::star::uno::Sequence< OUString > SAL_CALL impl_staticGetSupportedServiceNames(); diff --git a/include/comphelper/ofopxmlhelper.hxx b/include/comphelper/ofopxmlhelper.hxx index bd831158acb3..0c759bbbb382 100644 --- a/include/comphelper/ofopxmlhelper.hxx +++ b/include/comphelper/ofopxmlhelper.hxx @@ -62,7 +62,7 @@ class COMPHELPER_DLLPUBLIC OFOPXMLHelper : public cppu::WeakImplHelper1 < com::s throw( ::com::sun::star::uno::Exception ); public: - ~OFOPXMLHelper(); + virtual ~OFOPXMLHelper(); // returns sequence of elements, where each element is described by sequence of tags, // where each tag is described by StringPair ( First - name, Second - value ) diff --git a/include/comphelper/propagg.hxx b/include/comphelper/propagg.hxx index 3a7dec8271a5..5410d5d0ce34 100644 --- a/include/comphelper/propagg.hxx +++ b/include/comphelper/propagg.hxx @@ -256,7 +256,7 @@ public: virtual void SAL_CALL setFastPropertyValue_NoBroadcast( sal_Int32 _nHandle, const ::com::sun::star::uno::Any& _rValue ) throw ( ::com::sun::star::uno::Exception, std::exception ) SAL_OVERRIDE; protected: - ~OPropertySetAggregationHelper(); + virtual ~OPropertySetAggregationHelper(); virtual void SAL_CALL getFastPropertyValue(::com::sun::star::uno::Any& rValue, sal_Int32 nHandle) const SAL_OVERRIDE; void disposing(); diff --git a/include/comphelper/scoped_disposing_ptr.hxx b/include/comphelper/scoped_disposing_ptr.hxx index b029849b1dcd..033307b56de5 100644 --- a/include/comphelper/scoped_disposing_ptr.hxx +++ b/include/comphelper/scoped_disposing_ptr.hxx @@ -85,7 +85,7 @@ private: } } - ~TerminateListener() + virtual ~TerminateListener() { if ( m_xComponent.is() ) { diff --git a/include/comphelper/seqstream.hxx b/include/comphelper/seqstream.hxx index a5c27e2e07d7..d5729955000c 100644 --- a/include/comphelper/seqstream.hxx +++ b/include/comphelper/seqstream.hxx @@ -93,7 +93,7 @@ protected: ::osl::Mutex m_aMutex; protected: - ~OSequenceOutputStream() { if (m_bConnected) closeOutput(); } + virtual ~OSequenceOutputStream() { if (m_bConnected) closeOutput(); } public: /** constructs the object. Everything written into the stream through the XOutputStream methods will be forwarded -- cgit