HomePhabricator

Make SetBestChain() atomic
d33a9218abdaUnpublished

Unpublished Commit ยท Learn More

Repository Importing: This repository is still importing.

Description

Make SetBestChain() atomic

In case a reorganisation fails, the internal state could become
inconsistent (memory only). Previously, a cache per block connect
or disconnect action was used, so blocks could not be applied in
a partial way. Extend this to a cache for the entire reorganisation,
making it atomic entirely. This also simplifies the code a bit.

Details

Provenance
Pieter Wuille <pieter.wuille@gmail.com>Authored on Dec 1 2012, 15:46
deadalnixPushed on May 14 2017, 22:04
Parents
rABCcd7fb7d1deec: Merge pull request #2033 from sipa/kickconflicts
Branches
Unknown
Tags
Unknown

Event Timeline

Pieter Wuille <pieter.wuille@gmail.com> committed rABCd33a9218abda: Make SetBestChain() atomic (authored by Pieter Wuille <pieter.wuille@gmail.com>).Dec 2 2012, 00:43