aboutsummaryrefslogtreecommitdiffstats
path: root/core
diff options
context:
space:
mode:
authorMartin Holst Swende <martin@swende.se>2017-06-07 00:38:38 +0800
committerMartin Holst Swende <martin@swende.se>2017-06-07 00:38:38 +0800
commit1496b3aff6a537a1c5597ec55b8d3b25afded26c (patch)
treefd19f9f963ec0e636e8665fbaa7a956c53b987dd /core
parent3285a0fda37207ca1b79ac28e2c12c6f5efff89b (diff)
downloadgo-tangerine-1496b3aff6a537a1c5597ec55b8d3b25afded26c.tar
go-tangerine-1496b3aff6a537a1c5597ec55b8d3b25afded26c.tar.gz
go-tangerine-1496b3aff6a537a1c5597ec55b8d3b25afded26c.tar.bz2
go-tangerine-1496b3aff6a537a1c5597ec55b8d3b25afded26c.tar.lz
go-tangerine-1496b3aff6a537a1c5597ec55b8d3b25afded26c.tar.xz
go-tangerine-1496b3aff6a537a1c5597ec55b8d3b25afded26c.tar.zst
go-tangerine-1496b3aff6a537a1c5597ec55b8d3b25afded26c.zip
common/math, core/vm: Un-expose bigEndianByteAt, use correct terms for endianness
Diffstat (limited to 'core')
-rw-r--r--core/vm/instructions.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/core/vm/instructions.go b/core/vm/instructions.go
index bcaf18e8a..f5164fcdd 100644
--- a/core/vm/instructions.go
+++ b/core/vm/instructions.go
@@ -258,8 +258,8 @@ func opXor(pc *uint64, evm *EVM, contract *Contract, memory *Memory, stack *Stac
func opByte(pc *uint64, evm *EVM, contract *Contract, memory *Memory, stack *Stack) ([]byte, error) {
th, val := stack.pop(), stack.peek()
if th.Cmp(common.Big32) < 0 {
- b := math.BigEndian32ByteAt(val, int(th.Int64()))
- val.SetInt64(int64(b))
+ b := math.Byte(val, 32, int(th.Int64()))
+ val.SetUint64(uint64(b))
} else {
val.SetUint64(0)
}