Skip to content

Commit 13364a2

Browse files
committed
eth/downloader: reset the chain when parent is missing during processing
1 parent 745c368 commit 13364a2

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

eth/downloader/downloader.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -436,6 +436,8 @@ func (d *Downloader) process(peer *peer) error {
436436
if err != nil && core.IsParentErr(err) {
437437
glog.V(logger.Debug).Infoln("Aborting process due to missing parent.")
438438

439+
// XXX this needs a lot of attention
440+
blocks = nil
439441
break
440442
} else if err != nil {
441443
// immediatly unregister the false peer but do not disconnect

0 commit comments

Comments
 (0)