MCPcopy Create free account
hub / github.com/DNAProject/DNA / tryGetSyncHeaderLock

Method tryGetSyncHeaderLock

p2pserver/block_sync.go:645–653  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

643}
644
645func (this *BlockSyncMgr) tryGetSyncHeaderLock() bool {
646 this.lock.Lock()
647 defer this.lock.Unlock()
648 if this.syncHeaderLock {
649 return true
650 }
651 this.syncHeaderLock = true
652 return false
653}
654
655func (this *BlockSyncMgr) releaseSyncHeaderLock() {
656 this.lock.Lock()

Callers 1

syncHeaderMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected