33 if (
mapArgs.count(
"-sendalert"))
60 alert.
strStatusBar =
"URGENT: Upgrade required: see https://www.dash.org";
68 LogPrintf(
"ThreadSendAlert() : could not sign alert\n");
77 if (!alert2.CheckSignature(
Params().AlertKey()))
79 printf(
"ThreadSendAlert() : CheckSignature failed\n");
82 assert(alert2.vchMsg == alert.vchMsg);
83 assert(alert2.vchSig == alert.vchSig);
85 printf(
"\nThreadSendAlert:\n");
86 printf(
"hash=%s\n", alert2.GetHash().ToString().c_str());
87 printf(
"%s", alert2.ToString().c_str());
88 printf(
"vchMsg=%s\n",
HexStr(alert2.vchMsg).c_str());
89 printf(
"vchSig=%s\n",
HexStr(alert2.vchSig).c_str());
92 if (!
mapArgs.count(
"-sendalert"))
100 printf(
"ThreadSendAlert() : Sending alert\n");
104 if (alert2.RelayTo(pnode, connman))
106 printf(
"ThreadSendAlert() : Sent alert to %s\n", pnode->
addr.
ToString().c_str());
111 printf(
"ThreadSendAlert() : Alert sent to %d nodes\n", nSent);
void MilliSleep(int64_t n)
void ThreadSendAlert(CConnman &connman)
std::string HexStr(const T itbegin, const T itend, bool fSpaces=false)
std::string ToString(bool fUseGetnameinfo=true) const
size_t GetNodeCount(NumConnections num)
const CChainParams & Params()
int64_t GetAdjustedTime()
static const int CLIENT_VERSION
void ForEachNode(const Condition &cond, Callable &&func)
map< string, string > mapArgs