diff --git a/src/currency_core/blockchain_storage.h b/src/currency_core/blockchain_storage.h index cad2ca91..2ca28c2e 100644 --- a/src/currency_core/blockchain_storage.h +++ b/src/currency_core/blockchain_storage.h @@ -531,9 +531,9 @@ namespace currency - mutable critical_section m_invalid_blocks_lock; + mutable epee::critical_section m_invalid_blocks_lock; blocks_ext_by_hash m_invalid_blocks; // crypto::hash -> block_extended_info - mutable critical_section m_alternative_chains_lock; + mutable epee::critical_section m_alternative_chains_lock; alt_chain_container m_alternative_chains; // crypto::hash -> alt_block_extended_info std::unordered_map m_alternative_chains_txs; // tx_id -> how many alt blocks it related to (always >= 1) std::unordered_map> m_altblocks_keyimages; // key image -> list of alt blocks hashes where it appears in inputs @@ -557,7 +557,7 @@ namespace currency mutable wide_difficulty_type m_cached_next_pow_difficulty; mutable wide_difficulty_type m_cached_next_pos_difficulty; - mutable critical_section m_targetdata_cache_lock; + mutable epee::critical_section m_targetdata_cache_lock; mutable std::list > m_pos_targetdata_cache; mutable std::list > m_pow_targetdata_cache; //work like a cache to avoid recalculation on read operations diff --git a/src/currency_core/currency_core.h b/src/currency_core/currency_core.h index 354fd772..383ae47e 100644 --- a/src/currency_core/currency_core.h +++ b/src/currency_core/currency_core.h @@ -139,18 +139,18 @@ namespace currency tx_memory_pool m_mempool; i_currency_protocol* m_pprotocol; i_critical_error_handler* m_critical_error_handler; - critical_section m_incoming_tx_lock; + epee::critical_section m_incoming_tx_lock; miner m_miner; account_public_address m_miner_address; std::string m_config_folder; uint64_t m_stop_after_height; currency_protocol_stub m_protocol_stub; - math_helper::once_a_time_seconds<60*60*12, false> m_prune_alt_blocks_interval; - math_helper::once_a_time_seconds<60, true> m_check_free_space_interval; + epee::math_helper::once_a_time_seconds<60*60*12, false> m_prune_alt_blocks_interval; + epee::math_helper::once_a_time_seconds<60, true> m_check_free_space_interval; friend class tx_validate_inputs; std::atomic m_starter_message_showed; - critical_section m_blockchain_update_listeners_lock; + epee::critical_section m_blockchain_update_listeners_lock; std::vector m_blockchain_update_listeners; }; } diff --git a/src/currency_core/miner.h b/src/currency_core/miner.h index 69a4bdc7..ec011801 100644 --- a/src/currency_core/miner.h +++ b/src/currency_core/miner.h @@ -92,7 +92,7 @@ namespace currency volatile uint32_t m_stop; - ::critical_section m_template_lock; + epee::critical_section m_template_lock; block m_template; std::atomic m_template_no; std::atomic m_starter_nonce; @@ -101,15 +101,15 @@ namespace currency volatile uint32_t m_thread_index; volatile uint32_t m_threads_total; std::atomic m_pausers_count; - ::critical_section m_miners_count_lock; + epee::critical_section m_miners_count_lock; std::list m_threads; - ::critical_section m_threads_lock; + epee::critical_section m_threads_lock; i_miner_handler* m_phandler; //blockchain_storage& m_bc; account_public_address m_mine_address; - math_helper::once_a_time_seconds<5> m_update_block_template_interval; - math_helper::once_a_time_seconds<2> m_update_merge_hr_interval; + epee::math_helper::once_a_time_seconds<5> m_update_block_template_interval; + epee::math_helper::once_a_time_seconds<2> m_update_merge_hr_interval; std::vector m_extra_messages; miner_config m_config; std::string m_config_folder; diff --git a/src/currency_core/tx_pool.cpp b/src/currency_core/tx_pool.cpp index 581dfdb8..7f4d4495 100644 --- a/src/currency_core/tx_pool.cpp +++ b/src/currency_core/tx_pool.cpp @@ -40,6 +40,8 @@ DISABLE_VS_WARNINGS(4244 4345 4503) //'boost::foreach_detail_::or_' : decorated #define LOG_DEFAULT_CHANNEL "tx_pool" ENABLE_CHANNEL_BY_DEFAULT("tx_pool"); +using namespace epee; + namespace currency { //--------------------------------------------------------------------------------- diff --git a/src/currency_core/tx_pool.h b/src/currency_core/tx_pool.h index 4e660a68..c9de4748 100644 --- a/src/currency_core/tx_pool.h +++ b/src/currency_core/tx_pool.h @@ -6,7 +6,6 @@ #pragma once #include "include_base_utils.h" -using namespace epee; #include diff --git a/src/stratum/stratum_server.cpp b/src/stratum/stratum_server.cpp index f952cd7a..8ec41088 100644 --- a/src/stratum/stratum_server.cpp +++ b/src/stratum/stratum_server.cpp @@ -368,7 +368,7 @@ namespace void block_template_update_thread() { - log_space::log_singletone::set_thread_log_prefix("[ST]"); + epee::log_space::log_singletone::set_thread_log_prefix("[ST]"); while (!m_stop_flag) { if (is_core_syncronized() && epee::misc_utils::get_tick_count() - m_block_template_update_ts >= m_block_template_update_pediod_ms) diff --git a/src/wallet/wallets_manager.h b/src/wallet/wallets_manager.h index 77656785..45dec851 100644 --- a/src/wallet/wallets_manager.h +++ b/src/wallet/wallets_manager.h @@ -15,8 +15,6 @@ DISABLE_VS_WARNINGS(4503) #include "include_base_utils.h" #include "version.h" -using namespace epee; - #include "console_handler.h" #include "p2p/net_node.h" #include "currency_core/checkpoints_create.h"