mixin icon indicating copy to clipboard operation
mixin copied to clipboard

Fix rand.Read read less than 64 bytes issue on Mac OS X platform

Open learnforpractice opened this issue 3 years ago • 2 comments

learnforpractice avatar Mar 18 '21 14:03 learnforpractice

maybe io.ReadFull should fix this?

cedricfung avatar Jul 04 '21 13:07 cedricfung

maybe io.ReadFull should fix this?

rand.Read calls io.ReadFull inside, so replace rand.Read with io.ReadFull can't fix this issue.

See the source code in the following link:

https://golang.org/src/crypto/rand/rand.go?s=809:847#L13

learnforpractice avatar Jul 06 '21 13:07 learnforpractice