From d7e4844d85db591a2ea235dd1b081c76e2f5cb9d Mon Sep 17 00:00:00 2001 From: Sebastien Gonzalve Date: Tue, 12 Mar 2013 14:30:27 +0100 Subject: Remove no-non-virtual-dtor flag BZ: 111473 The warning non-virtual-dtor should not be ignored for the whole project, but only in the few cases where it it necessary. Change-Id: I0ede82a30f2cd055b789f7fb56104fb227934e6f Signed-off-by: Sebastien Gonzalve Signed-off-by: Guilhem IMBERTON Reviewed-on: http://android.intel.com:8080/110191 Reviewed-by: buildbot Tested-by: buildbot --- parameter/Android.mk | 3 --- parameter/AreaConfiguration.h | 3 +++ parameter/BackSynchronizer.h | 2 ++ parameter/Mapper.h | 3 +++ parameter/ParameterMgr.h | 2 ++ parameter/SubsystemObjectCreator.h | 2 ++ parameter/Syncer.h | 3 +++ parameter/include/ParameterMgrPlatformConnector.h | 2 ++ parameter/include/SelectionCriterionInterface.h | 3 +++ parameter/include/SelectionCriterionTypeInterface.h | 3 +++ remote-process/Android.mk | 2 -- remote-processor/Android.mk | 3 --- remote-processor/RemoteCommand.h | 3 +++ remote-processor/RemoteCommandHandler.h | 3 +++ remote-processor/RemoteCommandHandlerTemplate.h | 1 + remote-processor/RemoteProcessorServerInterface.h | 3 +++ test/test-platform/Android.mk | 3 --- test/test-platform/TestPlatform.cpp | 1 - xmlserializer/Android.mk | 2 -- xmlserializer/XmlDocSink.h | 1 + xmlserializer/XmlSink.h | 3 +++ xmlserializer/XmlSource.h | 3 +++ 22 files changed, 40 insertions(+), 14 deletions(-) diff --git a/parameter/Android.mk b/parameter/Android.mk index 02e1048..c4d57e0 100644 --- a/parameter/Android.mk +++ b/parameter/Android.mk @@ -100,8 +100,6 @@ COMMON_SRC_FILES := \ COMMON_MODULE := libparameter COMMON_MODULE_TAGS := optional -COMMON_CFLAGS := -Wno-non-virtual-dtor - COMMON_C_INCLUDES := \ $(LOCAL_PATH)/include/ \ $(LOCAL_PATH)/../utility/ \ @@ -110,7 +108,6 @@ COMMON_C_INCLUDES := \ COMMON_SHARED_LIBRARIES := libicuuc COMMON_STATIC_LIBRARIES := libxmlserializer libutility libxml2 - ############################# # Target build diff --git a/parameter/AreaConfiguration.h b/parameter/AreaConfiguration.h index bcf2229..bb1cc92 100644 --- a/parameter/AreaConfiguration.h +++ b/parameter/AreaConfiguration.h @@ -39,6 +39,9 @@ class CAreaConfiguration public: CAreaConfiguration(const CConfigurableElement* pConfigurableElement, const CSyncerSet* pSyncerSet); + /* FIXME this was missing and probably buggy*/ + virtual ~CAreaConfiguration() {} + // Save data from current void save(const CParameterBlackboard* pMainBlackboard); diff --git a/parameter/BackSynchronizer.h b/parameter/BackSynchronizer.h index 2c3cdac..793c687 100644 --- a/parameter/BackSynchronizer.h +++ b/parameter/BackSynchronizer.h @@ -38,10 +38,12 @@ public: // Back synchronization virtual void sync() = 0; + virtual ~CBackSynchronizer() {} protected: // Aggegate list list _needingBackSyncList; + private: // Aggegator CConfigurableElementAggregator _configurableElementAggregator; diff --git a/parameter/Mapper.h b/parameter/Mapper.h index 8bf7223..1d2dd22 100644 --- a/parameter/Mapper.h +++ b/parameter/Mapper.h @@ -35,4 +35,7 @@ class IMapper public: virtual bool mapBegin(CInstanceConfigurableElement* pInstanceConfigurableElement, bool& bKeepDiving, string& strError) = 0; virtual void mapEnd() = 0; + +protected: + virtual ~IMapper() {} }; diff --git a/parameter/ParameterMgr.h b/parameter/ParameterMgr.h index fa12128..0d7119d 100644 --- a/parameter/ParameterMgr.h +++ b/parameter/ParameterMgr.h @@ -92,6 +92,8 @@ public: { public: virtual void log(bool bIsWarning, const std::string& strLog) = 0; + protected: + virtual ~ILogger() {} }; // Construction diff --git a/parameter/SubsystemObjectCreator.h b/parameter/SubsystemObjectCreator.h index 0b55a57..98e4079 100644 --- a/parameter/SubsystemObjectCreator.h +++ b/parameter/SubsystemObjectCreator.h @@ -43,6 +43,8 @@ public: // Object creation virtual CSubsystemObject* objectCreate(const string& strMappingValue, CInstanceConfigurableElement* pInstanceConfigurableElement, const CMappingContext& context) const = 0; + virtual ~CSubsystemObjectCreator() {} + private: // Mapping key string _strMappingKey; diff --git a/parameter/Syncer.h b/parameter/Syncer.h index 0b830a8..b1632e8 100644 --- a/parameter/Syncer.h +++ b/parameter/Syncer.h @@ -34,4 +34,7 @@ class ISyncer { public: virtual bool sync(CParameterBlackboard& parameterBlackboard, bool bBack, string& strError) = 0; + +protected: + virtual ~ISyncer() {} }; diff --git a/parameter/include/ParameterMgrPlatformConnector.h b/parameter/include/ParameterMgrPlatformConnector.h index 64394e4..ae3e216 100644 --- a/parameter/include/ParameterMgrPlatformConnector.h +++ b/parameter/include/ParameterMgrPlatformConnector.h @@ -38,6 +38,8 @@ public: { public: virtual void log(bool bIsWarning, const std::string& strLog) = 0; + protected: + virtual ~ILogger() {} }; // Construction diff --git a/parameter/include/SelectionCriterionInterface.h b/parameter/include/SelectionCriterionInterface.h index 9162486..fe5301f 100644 --- a/parameter/include/SelectionCriterionInterface.h +++ b/parameter/include/SelectionCriterionInterface.h @@ -32,4 +32,7 @@ public: virtual int getCriterionState() const = 0; virtual std::string getCriterionName() const = 0; virtual const ISelectionCriterionTypeInterface* getCriterionType() const = 0; + +protected: + virtual ~ISelectionCriterionInterface() {} }; diff --git a/parameter/include/SelectionCriterionTypeInterface.h b/parameter/include/SelectionCriterionTypeInterface.h index 426d355..7d631d1 100644 --- a/parameter/include/SelectionCriterionTypeInterface.h +++ b/parameter/include/SelectionCriterionTypeInterface.h @@ -31,5 +31,8 @@ public: virtual bool getLiteralValue(int iValue, std::string& strValue) const = 0; virtual bool isTypeInclusive() const = 0; virtual std::string getFormattedState(int iValue) const = 0; + +protected: + virtual ~ISelectionCriterionTypeInterface() {} }; diff --git a/remote-process/Android.mk b/remote-process/Android.mk index dbdf6b5..8330e0a 100644 --- a/remote-process/Android.mk +++ b/remote-process/Android.mk @@ -9,7 +9,6 @@ COMMON_SRC_FILES := \ COMMON_MODULE := remote-process COMMON_MODULE_TAGS := optional -COMMON_CFLAGS := -Wno-non-virtual-dtor COMMON_C_INCLUDES := \ $(LOCAL_PATH)/../remote-processor/ @@ -27,7 +26,6 @@ LOCAL_MODULE := $(COMMON_MODULE) LOCAL_MODULE_TAGS := $(COMMON_MODULE_TAGS) LOCAL_CFLAGS += $(COMMON_CFLAGS) - LOCAL_C_INCLUDES += \ $(COMMON_C_INCLUDES) \ external/stlport/stlport/ \ diff --git a/remote-processor/Android.mk b/remote-processor/Android.mk index 7da064a..2a79297 100644 --- a/remote-processor/Android.mk +++ b/remote-processor/Android.mk @@ -16,10 +16,7 @@ COMMON_SRC_FILES := \ COMMON_MODULE := libremote-processor COMMON_MODULE_TAGS := optional -COMMON_CFLAGS := -Wno-non-virtual-dtor - COMMON_LDLIBS := -lpthread - ############################# # Target build diff --git a/remote-processor/RemoteCommand.h b/remote-processor/RemoteCommand.h index df3d5a4..ffcbcfc 100644 --- a/remote-processor/RemoteCommand.h +++ b/remote-processor/RemoteCommand.h @@ -38,4 +38,7 @@ public: virtual uint32_t getArgumentCount() const = 0; virtual const std::string& getArgument(uint32_t uiArgument) const = 0; virtual const std::string packArguments(uint32_t uiStartArgument, uint32_t uiNbArguments) const = 0; + +protected: + virtual ~IRemoteCommand() {} }; diff --git a/remote-processor/RemoteCommandHandler.h b/remote-processor/RemoteCommandHandler.h index 97aa04f..fcd98a9 100644 --- a/remote-processor/RemoteCommandHandler.h +++ b/remote-processor/RemoteCommandHandler.h @@ -32,4 +32,7 @@ class IRemoteCommandHandler public: // Return true on success, fill result in any cases virtual bool remoteCommandProcess(const IRemoteCommand& remoteCommand, std::string& strResult) = 0; + +protected: + virtual ~IRemoteCommandHandler() {} }; diff --git a/remote-processor/RemoteCommandHandlerTemplate.h b/remote-processor/RemoteCommandHandlerTemplate.h index 5d9817e..6223b9c 100644 --- a/remote-processor/RemoteCommandHandlerTemplate.h +++ b/remote-processor/RemoteCommandHandlerTemplate.h @@ -217,3 +217,4 @@ private: std::vector _remoteCommandParserVector; uint32_t _uiMaxCommandUsageLength; }; + diff --git a/remote-processor/RemoteProcessorServerInterface.h b/remote-processor/RemoteProcessorServerInterface.h index 11ceb10..fdc97cc 100644 --- a/remote-processor/RemoteProcessorServerInterface.h +++ b/remote-processor/RemoteProcessorServerInterface.h @@ -34,4 +34,7 @@ public: virtual bool start() = 0; virtual void stop() = 0; virtual bool isStarted() const = 0; + + /* FIXME this was missing but is explicitly called */ + virtual ~IRemoteProcessorServerInterface() {} }; diff --git a/test/test-platform/Android.mk b/test/test-platform/Android.mk index 845607f..759af73 100644 --- a/test/test-platform/Android.mk +++ b/test/test-platform/Android.mk @@ -10,14 +10,11 @@ COMMON_SRC_FILES := \ COMMON_MODULE := test-platform COMMON_MODULE_TAGS := optional -COMMON_CFLAGS := -Wno-non-virtual-dtor - COMMON_C_INCLUDES := \ $(LOCAL_PATH)/../../parameter/include \ $(LOCAL_PATH)/../../remote-processor/ COMMON_SHARED_LIBRARIES := libparameter libremote-processor - ############################# # Target build diff --git a/test/test-platform/TestPlatform.cpp b/test/test-platform/TestPlatform.cpp index 60ee644..91b86fd 100644 --- a/test/test-platform/TestPlatform.cpp +++ b/test/test-platform/TestPlatform.cpp @@ -49,7 +49,6 @@ public: } }; - CTestPlatform::CTestPlatform(const string& strClass, int iPortNumber) : _pParameterMgrPlatformConnector(new CParameterMgrPlatformConnector(strClass)), _pParameterMgrPlatformConnectorLogger(new CParameterMgrPlatformConnectorLogger) diff --git a/xmlserializer/Android.mk b/xmlserializer/Android.mk index 6d2770c..8ddb700 100644 --- a/xmlserializer/Android.mk +++ b/xmlserializer/Android.mk @@ -18,8 +18,6 @@ COMMON_MODULE := libxmlserializer COMMON_MODULE_TAGS := optional -COMMON_CFLAGS := -Wno-non-virtual-dtor - COMMON_C_INCLUDES := \ external/libxml2/include/ \ external/webkit/Source/WebCore/icu/ \ diff --git a/xmlserializer/XmlDocSink.h b/xmlserializer/XmlDocSink.h index e1b2fc3..d341ecf 100644 --- a/xmlserializer/XmlDocSink.h +++ b/xmlserializer/XmlDocSink.h @@ -34,6 +34,7 @@ public: // Source processing bool process(CXmlDocSource& xmlDocSource, CXmlSerializingContext& serializingContext); + virtual ~CXmlDocSink() {} private: // Handle for subclasses to process the source diff --git a/xmlserializer/XmlSink.h b/xmlserializer/XmlSink.h index 0d09a1d..dfa0686 100644 --- a/xmlserializer/XmlSink.h +++ b/xmlserializer/XmlSink.h @@ -31,4 +31,7 @@ class IXmlSink { public: virtual bool fromXml(const CXmlElement& xmlElement, CXmlSerializingContext& serializingContext) = 0; + +protected: + virtual ~IXmlSink() {} }; diff --git a/xmlserializer/XmlSource.h b/xmlserializer/XmlSource.h index 818298d..1a7c52e 100644 --- a/xmlserializer/XmlSource.h +++ b/xmlserializer/XmlSource.h @@ -31,4 +31,7 @@ class IXmlSource { public: virtual void toXml(CXmlElement& xmlElement, CXmlSerializingContext& serializingContext) const = 0; + +protected: + virtual ~IXmlSource() {} }; -- cgit v1.1