Skip to content

Commit fa4c075

Browse files
author
MarcoFalke
committed
doc: Clarify waitTipChanged docs
It should be obvious that a wait is not needed if the tip does not match. Also, remove a comment that the blockTip notification was only meant for the "UI". (It is used by other stuff for a long time)
1 parent fc642c3 commit fa4c075

File tree

2 files changed

+1
-3
lines changed

2 files changed

+1
-3
lines changed

src/interfaces/mining.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -64,8 +64,7 @@ class Mining
6464
* Waits for the tip to change
6565
*
6666
* @param[in] current_tip block hash of the current chain tip. Function waits
67-
* for the chain tip to change if this matches, otherwise
68-
* it returns right away.
67+
* for the chain tip to differ from this.
6968
* @param[in] timeout how long to wait for a new tip
7069
* @returns Hash and height of the current chain tip after this call.
7170
*/

src/validation.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3533,7 +3533,6 @@ bool Chainstate::ActivateBestChain(BlockValidationState& state, std::shared_ptr<
35333533
m_chainman.m_options.signals->UpdatedBlockTip(pindexNewTip, pindexFork, still_in_ibd);
35343534
}
35353535

3536-
// Always notify the UI if a new block tip was connected
35373536
if (kernel::IsInterrupted(m_chainman.GetNotifications().blockTip(GetSynchronizationState(still_in_ibd, m_chainman.m_blockman.m_blockfiles_indexed), *pindexNewTip))) {
35383537
// Just breaking and returning success for now. This could
35393538
// be changed to bubble up the kernel::Interrupted value to

0 commit comments

Comments
 (0)