Merge 74d9f4bd95 into merged_master (Bitcoin PR bitcoin/bitcoin#25068)

This commit is contained in:
James Dorfman 2024-08-09 05:37:14 +00:00
commit fcd2946158
8 changed files with 22 additions and 19 deletions

View file

@ -93,7 +93,6 @@
#include <sys/stat.h>
#endif
#include <boost/algorithm/string/replace.hpp>
#include <boost/signals2/signal.hpp>
#include <assetsdir.h> // InitGlobalAssetDir
@ -1784,7 +1783,7 @@ bool AppInitMain(NodeContext& node, interfaces::BlockAndHeaderTipInfo* tip_info)
uiInterface.NotifyBlockTip_connect([block_notify](SynchronizationState sync_state, const CBlockIndex* pBlockIndex) {
if (sync_state != SynchronizationState::POST_INIT || !pBlockIndex) return;
std::string command = block_notify;
boost::replace_all(command, "%s", pBlockIndex->GetBlockHash().GetHex());
ReplaceAll(command, "%s", pBlockIndex->GetBlockHash().GetHex());
std::thread t(runCommand, command);
t.detach(); // thread runs free
});