aboutsummaryrefslogtreecommitdiffstats
path: root/accounts/abi/argument.go
diff options
context:
space:
mode:
authorweimumu <934657014@qq.com>2018-12-28 15:43:55 +0800
committerGuillaume Ballet <gballet@gmail.com>2018-12-28 15:43:55 +0800
commit735343430dec74a340f5c9a18822537e18165caa (patch)
treeb8c889f5212b9598ffef5022958feb6afcddf4c3 /accounts/abi/argument.go
parent9e9fc87e70accf2b81be8772ab2ab0c914e95666 (diff)
downloaddexon-735343430dec74a340f5c9a18822537e18165caa.tar.gz
dexon-735343430dec74a340f5c9a18822537e18165caa.tar.zst
dexon-735343430dec74a340f5c9a18822537e18165caa.zip
fix string array unpack bug in accounts/abi (#18364)
Diffstat (limited to 'accounts/abi/argument.go')
-rw-r--r--accounts/abi/argument.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/accounts/abi/argument.go b/accounts/abi/argument.go
index f544c80db..90fd9d05f 100644
--- a/accounts/abi/argument.go
+++ b/accounts/abi/argument.go
@@ -202,7 +202,7 @@ func (arguments Arguments) UnpackValues(data []byte) ([]interface{}, error) {
virtualArgs := 0
for index, arg := range arguments.NonIndexed() {
marshalledValue, err := toGoType((index+virtualArgs)*32, arg.Type, data)
- if arg.Type.T == ArrayTy {
+ if arg.Type.T == ArrayTy && (*arg.Type.Elem).T != StringTy {
// If we have a static array, like [3]uint256, these are coded as
// just like uint256,uint256,uint256.
// This means that we need to add two 'virtual' arguments when