Skip to content

Commit fafddfa

Browse files
author
MarcoFalke
committed
scripted-diff: Remove shadowing lock annotations
Can be reviewed with --word-diff-regex=. -BEGIN VERIFY SCRIPT- sed -i --regexp-extended 's/(PeerManagerImpl::.*\)).*LOCKS_.*\)/\1/g' ./src/net_processing.cpp -END VERIFY SCRIPT-
1 parent 8d6994f commit fafddfa

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

src/net_processing.cpp

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -646,7 +646,7 @@ static void UpdatePreferredDownload(const CNode& node, CNodeState* state) EXCLUS
646646
nPreferredDownload += state->fPreferredDownload;
647647
}
648648

649-
bool PeerManagerImpl::MarkBlockAsReceived(const uint256& hash) EXCLUSIVE_LOCKS_REQUIRED(cs_main)
649+
bool PeerManagerImpl::MarkBlockAsReceived(const uint256& hash)
650650
{
651651
std::map<uint256, std::pair<NodeId, std::list<QueuedBlock>::iterator> >::iterator itInFlight = mapBlocksInFlight.find(hash);
652652
if (itInFlight != mapBlocksInFlight.end()) {
@@ -670,7 +670,7 @@ bool PeerManagerImpl::MarkBlockAsReceived(const uint256& hash) EXCLUSIVE_LOCKS_R
670670
return false;
671671
}
672672

673-
bool PeerManagerImpl::MarkBlockAsInFlight(NodeId nodeid, const uint256& hash, const CBlockIndex* pindex, std::list<QueuedBlock>::iterator** pit) EXCLUSIVE_LOCKS_REQUIRED(cs_main)
673+
bool PeerManagerImpl::MarkBlockAsInFlight(NodeId nodeid, const uint256& hash, const CBlockIndex* pindex, std::list<QueuedBlock>::iterator** pit)
674674
{
675675
CNodeState *state = State(nodeid);
676676
assert(state != nullptr);
@@ -739,7 +739,7 @@ static void UpdateBlockAvailability(NodeId nodeid, const uint256 &hash) EXCLUSIV
739739
}
740740
}
741741

742-
void PeerManagerImpl::MaybeSetPeerAsAnnouncingHeaderAndIDs(NodeId nodeid) EXCLUSIVE_LOCKS_REQUIRED(cs_main)
742+
void PeerManagerImpl::MaybeSetPeerAsAnnouncingHeaderAndIDs(NodeId nodeid)
743743
{
744744
AssertLockHeld(cs_main);
745745
CNodeState* nodestate = State(nodeid);
@@ -778,7 +778,7 @@ void PeerManagerImpl::MaybeSetPeerAsAnnouncingHeaderAndIDs(NodeId nodeid) EXCLUS
778778
}
779779
}
780780

781-
bool PeerManagerImpl::TipMayBeStale() EXCLUSIVE_LOCKS_REQUIRED(cs_main)
781+
bool PeerManagerImpl::TipMayBeStale()
782782
{
783783
AssertLockHeld(cs_main);
784784
const Consensus::Params& consensusParams = m_chainparams.GetConsensus();
@@ -802,7 +802,7 @@ static bool PeerHasHeader(CNodeState *state, const CBlockIndex *pindex) EXCLUSIV
802802
return false;
803803
}
804804

805-
void PeerManagerImpl::FindNextBlocksToDownload(NodeId nodeid, unsigned int count, std::vector<const CBlockIndex*>& vBlocks, NodeId& nodeStaller) EXCLUSIVE_LOCKS_REQUIRED(cs_main)
805+
void PeerManagerImpl::FindNextBlocksToDownload(NodeId nodeid, unsigned int count, std::vector<const CBlockIndex*>& vBlocks, NodeId& nodeStaller)
806806
{
807807
if (count == 0)
808808
return;
@@ -1591,7 +1591,7 @@ void PeerManagerImpl::BlockChecked(const CBlock& block, const BlockValidationSta
15911591
//
15921592

15931593

1594-
bool PeerManagerImpl::AlreadyHaveTx(const GenTxid& gtxid) EXCLUSIVE_LOCKS_REQUIRED(cs_main)
1594+
bool PeerManagerImpl::AlreadyHaveTx(const GenTxid& gtxid)
15951595
{
15961596
assert(recentRejects);
15971597
if (::ChainActive().Tip()->GetBlockHash() != hashRecentRejectsChainTip) {
@@ -1853,7 +1853,7 @@ void static ProcessGetBlockData(CNode& pfrom, Peer& peer, const CChainParams& ch
18531853
}
18541854
}
18551855

1856-
CTransactionRef PeerManagerImpl::FindTxForGetData(const CNode& peer, const GenTxid& gtxid, const std::chrono::seconds mempool_req, const std::chrono::seconds now) LOCKS_EXCLUDED(cs_main)
1856+
CTransactionRef PeerManagerImpl::FindTxForGetData(const CNode& peer, const GenTxid& gtxid, const std::chrono::seconds mempool_req, const std::chrono::seconds now)
18571857
{
18581858
auto txinfo = m_mempool.info(gtxid);
18591859
if (txinfo.tx) {
@@ -1880,7 +1880,7 @@ CTransactionRef PeerManagerImpl::FindTxForGetData(const CNode& peer, const GenTx
18801880
return {};
18811881
}
18821882

1883-
void PeerManagerImpl::ProcessGetData(CNode& pfrom, Peer& peer, const std::atomic<bool>& interruptMsgProc) EXCLUSIVE_LOCKS_REQUIRED(!cs_main, peer.m_getdata_requests_mutex)
1883+
void PeerManagerImpl::ProcessGetData(CNode& pfrom, Peer& peer, const std::atomic<bool>& interruptMsgProc)
18841884
{
18851885
AssertLockNotHeld(cs_main);
18861886

0 commit comments

Comments
 (0)