eth/downloader: fix leak in runStateSync

This commit is contained in:
Felix Lange 2017-05-31 03:30:33 +02:00 committed by Péter Szilágyi
parent baa79e9df0
commit 6588e66420
No known key found for this signature in database
GPG key ID: E9AE538CEDF8293D

View file

@ -115,7 +115,7 @@ func (d *Downloader) runStateSync(s *stateSync) *stateSync {
// Send the next finished request to the current sync:
case deliverReqCh <- deliverReq:
finishedReqs = finishedReqs[1:]
finishedReqs = append(finishedReqs[:0], finishedReqs[1:]...)
// Handle incoming state packs:
case pack := <-d.stateCh: