diff options
author | Maran <maran.hidskes@gmail.com> | 2014-07-22 18:16:09 +0800 |
---|---|---|
committer | Maran <maran.hidskes@gmail.com> | 2014-07-22 18:16:09 +0800 |
commit | 9c86e99968b0756a689a4100231117e5e2211127 (patch) | |
tree | 337558902e7558d3588a22bf35704f815cfd754b | |
parent | 8f91d47bf3c26b850f0f40f79856141087e6ef82 (diff) | |
parent | 6774ddaba29ae9e9db5065ce74055297b948adf9 (diff) | |
download | go-tangerine-9c86e99968b0756a689a4100231117e5e2211127.tar.gz go-tangerine-9c86e99968b0756a689a4100231117e5e2211127.tar.zst go-tangerine-9c86e99968b0756a689a4100231117e5e2211127.zip |
Merge branch 'master' into develop
-rw-r--r-- | ethchain/vm.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ethchain/vm.go b/ethchain/vm.go index 9d47f950d..34ecd95b7 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]) |