Juan Pablo Civile e874baf090 Release v0.2.0
2019-12-17 17:32:12 -03:00

17 lines
251 B
Go

package libwallet
import (
"math/big"
)
func paddedSerializeBigInt(size uint, x *big.Int) []byte {
src := x.Bytes()
dst := make([]byte, 0, size)
for i := 0; i < int(size)-len(src); i++ {
dst = append(dst, 0)
}
return append(dst, src...)
}