-
Notifications
You must be signed in to change notification settings - Fork 78
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
'decoder.go / encoder.go' overflows int issue when cross compile c(for android) #245
Comments
Thanks for raising this issue! This should have been fixed with #242 though. Did you try to cross-compile amino from the latest master, or the tagged release |
OK, I see. cosmos-sdk v0.26.1-rc1 uses |
I'm, sorry. I accidentally made a pull request to the master brench. |
No problem. We can change the base branch to develop. Thanks! I'm still sure this problem doesn't exist in the latest release though. Can you try to cross-compile amino 0.14.1? Does the problem still persist? |
The issue has been resolved with 0.14.1! Thank you! |
I've cross-compile cosmos-sdk v0.26.1-rc1 with c(androideabi).
However, an error has occurred.
[Got message]
../../../../vendor/github.com/tendermint/go-amino/decoder.go:246:44: constant -62135596800 overflows int
../../../../vendor/github.com/tendermint/go-amino/decoder.go:246:44: constant 253402300800 overflows int
../../../../vendor/github.com/tendermint/go-amino/encoder.go:147:38: constant -62135596800 overflows int
../../../../vendor/github.com/tendermint/go-amino/encoder.go:147:38: constant 253402300800 overflows int
[Please change both files.]
1. go-amino/decoder.go:246
return 0, n, InvalidTimeErr(fmt.Sprintf("seconds have to be > %d and < %d, got: %d",
minSeconds, maxSeconds, res))
to
return 0, n, InvalidTimeErr(fmt.Sprintf("seconds have to be > %d and < %d, got: %d",
int64(minSeconds), int64(maxSeconds), res))
2. go-amino/encoder.go:147
return InvalidTimeErr(fmt.Sprintf("seconds have to be >= %d and < %d, got: %d",
minSeconds, maxSeconds, s))
to
return InvalidTimeErr(fmt.Sprintf("seconds have to be >= %d and < %d, got: %d",
int64(minSeconds), int64(maxSeconds), s))
Thank you for your hard work.
The text was updated successfully, but these errors were encountered: