aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAlex Morcos <morcos@chaincode.com>2015-10-28 14:56:28 -0400
committerAlex Morcos <morcos@chaincode.com>2015-12-01 10:10:25 -0500
commit5f122633020ce5d9f78c73394cda576a8657a3ac (patch)
treeb12d5bef8c24b435bdc7e158b74692f4ca672436 /src
parent1f09287c667d3a7d10ab9c5c96037fe48899490d (diff)
Expose FormatStateMessage
Diffstat (limited to 'src')
-rw-r--r--src/main.cpp2
-rw-r--r--src/main.h2
2 files changed, 3 insertions, 1 deletions
diff --git a/src/main.cpp b/src/main.cpp
index fb6d32b2fc..e9e9820434 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -816,7 +816,7 @@ CAmount GetMinRelayFee(const CTransaction& tx, const CTxMemPool& pool, unsigned
}
/** Convert CValidationState to a human-readable message for logging */
-static std::string FormatStateMessage(const CValidationState &state)
+std::string FormatStateMessage(const CValidationState &state)
{
return strprintf("%s%s (code %i)",
state.GetRejectReason(),
diff --git a/src/main.h b/src/main.h
index 16dff28363..19623f4d96 100644
--- a/src/main.h
+++ b/src/main.h
@@ -257,6 +257,8 @@ void PruneAndFlush();
bool AcceptToMemoryPool(CTxMemPool& pool, CValidationState &state, const CTransaction &tx, bool fLimitFree,
bool* pfMissingInputs, bool fOverrideMempoolLimit=false, bool fRejectAbsurdFee=false);
+/** Convert CValidationState to a human-readable message for logging */
+std::string FormatStateMessage(const CValidationState &state);
struct CNodeStateStats {
int nMisbehavior;