QuarkChain / go-ethereum

Official Go implementation of the Ethereum protocol
https://geth.ethereum.org
GNU Lesser General Public License v3.0
5 stars 2 forks source link

fix chunkIdx bug #114

Closed cyl19970726 closed 1 year ago

cyl19970726 commented 1 year ago

The current ChunkIdx is calculated as follows in older versions of the code:

This caused an error: ds.ChunkIdx() and kvIdx*ds.chunksPerKv have overlapping calculations

In my perspective, the correct calculation formula for current ChunkIdx is as follows :

blockchaindevsh commented 1 year ago

Suggest to rename ChunkIdx() to StartChunkIdx() in order to avoid confusion.