diff --git a/src/currency_core/bc_attachments_service_manager.h b/src/currency_core/bc_attachments_service_manager.h index 8f95d699..bd4f2640 100644 --- a/src/currency_core/bc_attachments_service_manager.h +++ b/src/currency_core/bc_attachments_service_manager.h @@ -12,6 +12,8 @@ namespace currency { struct i_bc_service { + virtual ~i_bc_service() = default; + virtual std::string get_id() = 0; virtual bool init(const std::string& config_folder, const boost::program_options::variables_map& vm) = 0; virtual bool deinit() = 0; diff --git a/src/simplewallet/simplewallet.h b/src/simplewallet/simplewallet.h index 2b138841..70fa3f85 100644 --- a/src/simplewallet/simplewallet.h +++ b/src/simplewallet/simplewallet.h @@ -22,7 +22,7 @@ namespace currency /************************************************************************/ /* */ /************************************************************************/ - class simple_wallet : public tools::i_wallet2_callback, + class simple_wallet final : public tools::i_wallet2_callback, public std::enable_shared_from_this { public: diff --git a/src/wallet/core_default_rpc_proxy.h b/src/wallet/core_default_rpc_proxy.h index 6ac1b111..ec43ab5f 100644 --- a/src/wallet/core_default_rpc_proxy.h +++ b/src/wallet/core_default_rpc_proxy.h @@ -16,7 +16,7 @@ namespace tools { - class default_http_core_proxy: public i_core_proxy + class default_http_core_proxy final : public i_core_proxy { public: diff --git a/src/wallet/core_rpc_proxy.h b/src/wallet/core_rpc_proxy.h index 71a06eff..9ea481f2 100644 --- a/src/wallet/core_rpc_proxy.h +++ b/src/wallet/core_rpc_proxy.h @@ -16,6 +16,8 @@ namespace tools */ struct i_core_proxy { + virtual ~i_core_proxy() = default; + virtual bool set_connection_addr(const std::string& url){ return false; } virtual bool call_COMMAND_RPC_GET_TX_GLOBAL_OUTPUTS_INDEXES(const currency::COMMAND_RPC_GET_TX_GLOBAL_OUTPUTS_INDEXES::request& rqt, currency::COMMAND_RPC_GET_TX_GLOBAL_OUTPUTS_INDEXES::response& rsp){ return false; } virtual bool call_COMMAND_RPC_GET_BLOCKS_FAST(const currency::COMMAND_RPC_GET_BLOCKS_FAST::request& rqt, currency::COMMAND_RPC_GET_BLOCKS_FAST::response& rsp){ return false; } diff --git a/src/wallet/wallet2.h b/src/wallet/wallet2.h index 819fde3f..66440855 100644 --- a/src/wallet/wallet2.h +++ b/src/wallet/wallet2.h @@ -68,6 +68,8 @@ namespace tools class i_wallet2_callback { public: + virtual ~i_wallet2_callback() = default; + virtual void on_new_block(uint64_t /*height*/, const currency::block& /*block*/) {} virtual void on_transfer2(const wallet_rpc::wallet_transfer_info& wti, uint64_t balance, uint64_t unlocked_balance, uint64_t total_mined) {} virtual void on_pos_block_found(const currency::block& /*block*/) {} @@ -1204,4 +1206,4 @@ namespace tools #undef LOG_DEFAULT_CHANNEL #define LOG_DEFAULT_CHANNEL "wallet" -ENABLE_CHANNEL_BY_DEFAULT("wallet"); \ No newline at end of file +ENABLE_CHANNEL_BY_DEFAULT("wallet"); diff --git a/tests/core_tests/test_core_proxy.h b/tests/core_tests/test_core_proxy.h index eaad9e51..83694ecd 100644 --- a/tests/core_tests/test_core_proxy.h +++ b/tests/core_tests/test_core_proxy.h @@ -12,6 +12,8 @@ class test_core_listener { public: + virtual ~test_core_listener() = default; + virtual void before_tx_pushed_to_core(const currency::transaction& tx, const currency::blobdata& blob, currency::core& c, bool invalid_tx = false) {} // invalid_tx is true when processing a tx, marked as invalid in a test virtual void before_block_pushed_to_core(const currency::block& block, const currency::blobdata& blob, currency::core& c) {} };