We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3761a44 commit 6e5b996Copy full SHA for 6e5b996
sync/src/block/downloader/header.rs
@@ -62,6 +62,10 @@ impl HeaderDownloader {
62
}
63
64
65
+ pub fn update_pivot(&mut self, hash: BlockHash) {
66
+ self.pivot = hash;
67
+ }
68
+
69
pub fn best_hash(&self) -> BlockHash {
70
self.best_hash
71
sync/src/block/extension.rs
@@ -1044,6 +1044,10 @@ impl Extension {
1044
1045
fn transition_to_full(&mut self) {
1046
cdebug!(SYNC, "Transitioning state to {:?}", State::Full);
1047
+ let best_hash = self.client.best_block_header().hash();
1048
+ for downloader in self.header_downloaders.values_mut() {
1049
+ downloader.update_pivot(best_hash);
1050
1051
self.state = State::Full;
1052
1053
0 commit comments