aboutsummaryrefslogtreecommitdiffstats
path: root/ethchain
diff options
context:
space:
mode:
authorMaran <maran.hidskes@gmail.com>2014-07-21 20:35:37 +0800
committerMaran <maran.hidskes@gmail.com>2014-07-21 20:35:37 +0800
commit6774ddaba29ae9e9db5065ce74055297b948adf9 (patch)
tree59d292b2c0d8af0e4869f24dbef1d98204322abe /ethchain
parent5d2669dbd35b9449cbbb249dcec89e2a64c90f30 (diff)
downloaddexon-6774ddaba29ae9e9db5065ce74055297b948adf9.tar.gz
dexon-6774ddaba29ae9e9db5065ce74055297b948adf9.tar.zst
dexon-6774ddaba29ae9e9db5065ce74055297b948adf9.zip
Fix regression on 32bit (windows) systems
Diffstat (limited to 'ethchain')
-rw-r--r--ethchain/vm.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/ethchain/vm.go b/ethchain/vm.go
index 4fdf8b31a..528088a49 100644
--- a/ethchain/vm.go
+++ b/ethchain/vm.go
@@ -506,7 +506,7 @@ func (vm *Vm) RunClosure(closure *Closure) (ret []byte, err error) {
offset := stack.Pop().Int64()
data := make([]byte, 32)
- if len(closure.Args) >= int(offset) {
+ if big.NewInt(int64(len(closure.Args))).Cmp(big.NewInt(offset)) >= 0 {
l := int64(math.Min(float64(offset+32), float64(len(closure.Args))))
copy(data, closure.Args[offset:l])