mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-05-13 19:46:39 +00:00
Merge pull request #14697 from homotopycolimit/master
swarm/storage: remove panic on invalid chunk
This commit is contained in:
commit
fdf2184b1e
1 changed files with 1 additions and 1 deletions
|
|
@ -399,7 +399,7 @@ func (s *DbStore) Get(key Key) (chunk *Chunk, err error) {
|
||||||
hash := hasher.Sum(nil)
|
hash := hasher.Sum(nil)
|
||||||
if !bytes.Equal(hash, key) {
|
if !bytes.Equal(hash, key) {
|
||||||
s.delete(index.Idx, getIndexKey(key))
|
s.delete(index.Idx, getIndexKey(key))
|
||||||
panic("Invalid Chunk in Database. Please repair with command: 'swarm cleandb'")
|
log.Warn("Invalid Chunk in Database. Please repair with command: 'swarm cleandb'")
|
||||||
}
|
}
|
||||||
|
|
||||||
chunk = &Chunk{
|
chunk = &Chunk{
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue