Merge pull request #2541
15e62581
connection_context: initialize m_callback_request_count to 0 (moneromooo-monero)5fa199c6
copyable_atomic: add a ctor with initial value (moneromooo-monero)
This commit is contained in:
commit
e8a7291d12
|
@ -35,6 +35,8 @@ namespace epee
|
||||||
public:
|
public:
|
||||||
copyable_atomic()
|
copyable_atomic()
|
||||||
{};
|
{};
|
||||||
|
copyable_atomic(uint32_t value)
|
||||||
|
{ store(value); }
|
||||||
copyable_atomic(const copyable_atomic& a):std::atomic<uint32_t>(a.load())
|
copyable_atomic(const copyable_atomic& a):std::atomic<uint32_t>(a.load())
|
||||||
{}
|
{}
|
||||||
copyable_atomic& operator= (const copyable_atomic& a)
|
copyable_atomic& operator= (const copyable_atomic& a)
|
||||||
|
|
|
@ -40,7 +40,7 @@ namespace cryptonote
|
||||||
struct cryptonote_connection_context: public epee::net_utils::connection_context_base
|
struct cryptonote_connection_context: public epee::net_utils::connection_context_base
|
||||||
{
|
{
|
||||||
cryptonote_connection_context(): m_state(state_before_handshake), m_remote_blockchain_height(0), m_last_response_height(0),
|
cryptonote_connection_context(): m_state(state_before_handshake), m_remote_blockchain_height(0), m_last_response_height(0),
|
||||||
m_last_known_hash(crypto::null_hash) {}
|
m_callback_request_count(0), m_last_known_hash(crypto::null_hash) {}
|
||||||
|
|
||||||
enum state
|
enum state
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue