mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-19 18:32:23 +00:00
eth/downloader: alloc mem for context
This commit is contained in:
parent
e85e21c932
commit
0d271ae5af
1 changed files with 1 additions and 1 deletions
|
|
@ -1024,7 +1024,7 @@ func (s *skeleton) processResponse(res *headerResponse) (linked bool, merged boo
|
||||||
// the syncer's internal state is corrupted. Do try to fix it, but
|
// the syncer's internal state is corrupted. Do try to fix it, but
|
||||||
// be very vocal about the fault.
|
// be very vocal about the fault.
|
||||||
default:
|
default:
|
||||||
var context []interface{}
|
context := make([]interface{}, 0, len(s.progress.Subchains[1:])*6)
|
||||||
|
|
||||||
for i := range s.progress.Subchains[1:] {
|
for i := range s.progress.Subchains[1:] {
|
||||||
context = append(context, fmt.Sprintf("stale_head_%d", i+1))
|
context = append(context, fmt.Sprintf("stale_head_%d", i+1))
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue