Go-ipfs: error: rabin chunker parameter [min]

Created on 5 Sep 2018  路  8Comments  路  Source: ipfs/go-ipfs

Version information:

0.4.17

Type:

Bug (probably)

Description:
// QmZooytqEoUwQjv7KzH4d3xyJnyvD3AWJaCDMYt5pbCtua\chunker\chunker.go
func (c *Chunker) reset() {
...
c.pre = c.MinSize - windowSize
}
windowSize = 16,c.pre data type is uint64,when first enters,c.MinSize=[min],if [min]<16, --->c.pre<0,cause the file will not be blocked.

Suggest:check the command line arguments:rabin-[min]-[avg]-[max], if min<16, return an error.

kinbug

Most helpful comment

hey @schomatis @Stebalien , i want to fix this,because i want to know more about chuncker.WDYT?

All 8 comments

Correct, this is a bug.

hey @schomatis @Stebalien , i want to fix this,because i want to know more about chuncker.WDYT?

Go ahead. It should be a relatively straight-forward fix.

Thanks @kjzz! Let me know if you need any help.

Merged. We can keep this open till we update the dep here.

@Stebalien Thx a lot,maybe i can add some test after go-ipfs-chunker publish new version.

The dep has been updated. @kjzz has submitted tests in #5449; we can close this once that gets merged.

Thanks @kjzz!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

magik6k picture magik6k  路  3Comments

daviddias picture daviddias  路  3Comments

kallisti5 picture kallisti5  路  3Comments

0x6431346e picture 0x6431346e  路  3Comments

ArcticLampyrid picture ArcticLampyrid  路  3Comments