Lock simple-scrypt library to master branch
The master branch includes a fix for i386, otherwise the calibration panics. See https://github.com/restic/restic/issues/676 for details.
This commit is contained in:
parent
4477d76f03
commit
41c35b2218
7 changed files with 148 additions and 20 deletions
2
vendor/github.com/elithrar/simple-scrypt/scrypt.go
generated
vendored
2
vendor/github.com/elithrar/simple-scrypt/scrypt.go
generated
vendored
|
@ -260,7 +260,7 @@ func Calibrate(timeout time.Duration, memMiBytes int, params Params) (Params, er
|
|||
var again bool
|
||||
memBytes := memMiBytes << 20
|
||||
// If we'd use more memory then the allowed, we can tune the memory usage
|
||||
for 128*p.R*p.N > memBytes {
|
||||
for 128*int64(p.R)*int64(p.N) > int64(memBytes) {
|
||||
if p.R > 1 {
|
||||
// by lowering r
|
||||
p.R--
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue