diff options
Diffstat (limited to 'contrib/epee')
-rw-r--r-- | contrib/epee/include/net/abstract_tcp_server2.inl | 6 | ||||
-rw-r--r-- | contrib/epee/src/mlog.cpp | 6 | ||||
-rw-r--r-- | contrib/epee/src/readline_buffer.cpp | 1 |
3 files changed, 7 insertions, 6 deletions
diff --git a/contrib/epee/include/net/abstract_tcp_server2.inl b/contrib/epee/include/net/abstract_tcp_server2.inl index 0fbd9ed28..61276e761 100644 --- a/contrib/epee/include/net/abstract_tcp_server2.inl +++ b/contrib/epee/include/net/abstract_tcp_server2.inl @@ -209,14 +209,14 @@ PRAGMA_WARNING_DISABLE_VS(4355) bool connection<t_protocol_handler>::add_ref() { TRY_ENTRY(); - //_dbg3("[sock " << socket_.native_handle() << "] add_ref, m_peer_number=" << mI->m_peer_number); - CRITICAL_REGION_LOCAL(m_self_refs_lock); - //_dbg3("[sock " << socket_.native_handle() << "] add_ref 2, m_peer_number=" << mI->m_peer_number); // Use safe_shared_from_this, because of this is public method and it can be called on the object being deleted auto self = safe_shared_from_this(); if(!self) return false; + //_dbg3("[sock " << socket_.native_handle() << "] add_ref, m_peer_number=" << mI->m_peer_number); + CRITICAL_REGION_LOCAL(self->m_self_refs_lock); + //_dbg3("[sock " << socket_.native_handle() << "] add_ref 2, m_peer_number=" << mI->m_peer_number); if(m_was_shutdown) return false; m_self_refs.push_back(self); diff --git a/contrib/epee/src/mlog.cpp b/contrib/epee/src/mlog.cpp index 3be992374..a51654d36 100644 --- a/contrib/epee/src/mlog.cpp +++ b/contrib/epee/src/mlog.cpp @@ -91,10 +91,10 @@ static const char *get_default_categories(int level) switch (level) { case 0: - categories = "*:WARNING,net:FATAL,net.p2p:FATAL,net.cn:FATAL,global:INFO,verify:FATAL,stacktrace:INFO,logging:INFO"; + categories = "*:WARNING,net:FATAL,net.p2p:FATAL,net.cn:FATAL,global:INFO,verify:FATAL,stacktrace:INFO,logging:INFO,msgwriter:INFO"; break; case 1: - categories = "*:WARNING,global:INFO,stacktrace:INFO,logging:INFO"; + categories = "*:WARNING,global:INFO,stacktrace:INFO,logging:INFO,msgwriter:INFO"; break; case 2: categories = "*:DEBUG"; @@ -139,7 +139,7 @@ void mlog_configure(const std::string &filename_base, bool console) { monero_log = get_default_categories(0); } - mlog_set_categories(monero_log); + mlog_set_log(monero_log); } void mlog_set_categories(const char *categories) diff --git a/contrib/epee/src/readline_buffer.cpp b/contrib/epee/src/readline_buffer.cpp index 92c0892f7..549f49d45 100644 --- a/contrib/epee/src/readline_buffer.cpp +++ b/contrib/epee/src/readline_buffer.cpp @@ -62,6 +62,7 @@ void rdln::readline_buffer::start() void rdln::readline_buffer::stop() { std::unique_lock<std::mutex> lock(process_mutex); + have_line.notify_all(); if(m_cout_buf == NULL) return; std::cout.rdbuf(m_cout_buf); |