Merge pull request #940 from filecoin-project/fix/units-parse

Use power of 2 sizes when parsing byte counts
This commit is contained in:
Łukasz Magiera 2019-12-16 21:36:21 +01:00 committed by GitHub
commit 4036f09610
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View File

@ -17,7 +17,7 @@ var fetchParamCmd = &cli.Command{
},
},
Action: func(cctx *cli.Context) error {
sectorSizeInt, err := units.FromHumanSize(cctx.String("proving-params"))
sectorSizeInt, err := units.RAMInBytes(cctx.String("proving-params"))
if err != nil {
return err
}

View File

@ -129,7 +129,7 @@ func main() {
return err
}
sectorSizeInt, err := units.FromHumanSize(c.String("sector-size"))
sectorSizeInt, err := units.RAMInBytes(c.String("sector-size"))
if err != nil {
return err
}