aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authortobtoht <tob@featherwallet.org>2025-11-11 21:51:35 +0000
committertobtoht <tob@featherwallet.org>2025-11-11 21:51:35 +0000
commit8167ae5ef0e3e4f6054af8521adeaf9bf31b9f52 (patch)
treea152e55dfff1e3b4a84dd83ae8648d15e189a21d /src
parent3cc9d65c9374b541e64320052c933184944375ea (diff)
parenta83a46d60059a063ec953ba15f4cdcc2b3874440 (diff)
downloadmonzero-core-8167ae5ef0e3e4f6054af8521adeaf9bf31b9f52.tar.gz
monzero-core-8167ae5ef0e3e4f6054af8521adeaf9bf31b9f52.tar.xz
monzero-core-8167ae5ef0e3e4f6054af8521adeaf9bf31b9f52.zip
Merge pull request #10194
a83a46d Fix logging deadlock (j-berman)
Diffstat (limited to 'src')
-rw-r--r--src/cryptonote_protocol/cryptonote_protocol_handler.inl7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/cryptonote_protocol/cryptonote_protocol_handler.inl b/src/cryptonote_protocol/cryptonote_protocol_handler.inl
index 2a6ad658d..1686394c5 100644
--- a/src/cryptonote_protocol/cryptonote_protocol_handler.inl
+++ b/src/cryptonote_protocol/cryptonote_protocol_handler.inl
@@ -44,6 +44,7 @@
#include "net/network_throttle-detail.hpp"
#include "common/pruning.h"
#include "common/util.h"
+#include "misc_log_ex.h"
#undef MONERO_DEFAULT_LOG_CATEGORY
#define MONERO_DEFAULT_LOG_CATEGORY "net.cn"
@@ -55,8 +56,10 @@
const char *cat = "net.p2p.msg"; \
if (ELPP->vRegistry()->allowed(level, cat)) { \
init; \
- if (test) \
- el::base::Writer(level, el::Color::Default, __FILE__, __LINE__, ELPP_FUNC, el::base::DispatchAction::NormalLog).construct(cat) << x; \
+ if (test) { \
+ LOG_TO_STRING(x); \
+ el::base::Writer(level, el::Color::Default, __FILE__, __LINE__, ELPP_FUNC, el::base::DispatchAction::NormalLog).construct(cat) << str; \
+ } \
} \
} while(0)