Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
G
Geth-Modification
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
张蕾
Geth-Modification
Commits
e761255b
Unverified
Commit
e761255b
authored
Nov 19, 2021
by
Martin Holst Swende
Committed by
GitHub
Nov 19, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
cmd/evm: make t9n intrinsicGas output hex, fixes #23883 (#23889)
parent
c52def7f
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
8 additions
and
8 deletions
+8
-8
transaction.go
cmd/evm/internal/t8ntool/transaction.go
+2
-2
exp2.json
cmd/evm/testdata/15/exp2.json
+2
-2
exp.json
cmd/evm/testdata/16/exp.json
+2
-2
exp.json
cmd/evm/testdata/17/exp.json
+2
-2
No files found.
cmd/evm/internal/t8ntool/transaction.go
View file @
e761255b
...
@@ -48,7 +48,7 @@ func (r *result) MarshalJSON() ([]byte, error) {
...
@@ -48,7 +48,7 @@ func (r *result) MarshalJSON() ([]byte, error) {
Error
string
`json:"error,omitempty"`
Error
string
`json:"error,omitempty"`
Address
*
common
.
Address
`json:"address,omitempty"`
Address
*
common
.
Address
`json:"address,omitempty"`
Hash
*
common
.
Hash
`json:"hash,omitempty"`
Hash
*
common
.
Hash
`json:"hash,omitempty"`
IntrinsicGas
uint64
`json:"intrinsicGas,omitempty"`
IntrinsicGas
hexutil
.
Uint64
`json:"intrinsicGas,omitempty"`
}
}
var
out
xx
var
out
xx
if
r
.
Error
!=
nil
{
if
r
.
Error
!=
nil
{
...
@@ -60,7 +60,7 @@ func (r *result) MarshalJSON() ([]byte, error) {
...
@@ -60,7 +60,7 @@ func (r *result) MarshalJSON() ([]byte, error) {
if
r
.
Hash
!=
(
common
.
Hash
{})
{
if
r
.
Hash
!=
(
common
.
Hash
{})
{
out
.
Hash
=
&
r
.
Hash
out
.
Hash
=
&
r
.
Hash
}
}
out
.
IntrinsicGas
=
r
.
IntrinsicGas
out
.
IntrinsicGas
=
hexutil
.
Uint64
(
r
.
IntrinsicGas
)
return
json
.
Marshal
(
out
)
return
json
.
Marshal
(
out
)
}
}
...
...
cmd/evm/testdata/15/exp2.json
View file @
e761255b
...
@@ -2,11 +2,11 @@
...
@@ -2,11 +2,11 @@
{
{
"address"
:
"0xd02d72e067e77158444ef2020ff2d325f929b363"
,
"address"
:
"0xd02d72e067e77158444ef2020ff2d325f929b363"
,
"hash"
:
"0xa98a24882ea90916c6a86da650fbc6b14238e46f0af04a131ce92be897507476"
,
"hash"
:
"0xa98a24882ea90916c6a86da650fbc6b14238e46f0af04a131ce92be897507476"
,
"intrinsicGas"
:
21000
"intrinsicGas"
:
"0x5208"
},
},
{
{
"address"
:
"0xd02d72e067e77158444ef2020ff2d325f929b363"
,
"address"
:
"0xd02d72e067e77158444ef2020ff2d325f929b363"
,
"hash"
:
"0x36bad80acce7040c45fd32764b5c2b2d2e6f778669fb41791f73f546d56e739a"
,
"hash"
:
"0x36bad80acce7040c45fd32764b5c2b2d2e6f778669fb41791f73f546d56e739a"
,
"intrinsicGas"
:
21000
"intrinsicGas"
:
"0x5208"
}
}
]
]
cmd/evm/testdata/16/exp.json
View file @
e761255b
...
@@ -2,12 +2,12 @@
...
@@ -2,12 +2,12 @@
{
{
"address"
:
"0xa94f5374fce5edbc8e2a8697c15331677e6ebf0b"
,
"address"
:
"0xa94f5374fce5edbc8e2a8697c15331677e6ebf0b"
,
"hash"
:
"0x7cc3d1a8540a44736750f03bb4d85c0113be4b3472a71bf82241a3b261b479e6"
,
"hash"
:
"0x7cc3d1a8540a44736750f03bb4d85c0113be4b3472a71bf82241a3b261b479e6"
,
"intrinsicGas"
:
21000
"intrinsicGas"
:
"0x5208"
},
},
{
{
"error"
:
"intrinsic gas too low: have 82, want 21000"
,
"error"
:
"intrinsic gas too low: have 82, want 21000"
,
"address"
:
"0xa94f5374fce5edbc8e2a8697c15331677e6ebf0b"
,
"address"
:
"0xa94f5374fce5edbc8e2a8697c15331677e6ebf0b"
,
"hash"
:
"0x3b2d2609e4361562edb9169314f4c05afc6dbf5d706bf9dda5abe242ab76a22b"
,
"hash"
:
"0x3b2d2609e4361562edb9169314f4c05afc6dbf5d706bf9dda5abe242ab76a22b"
,
"intrinsicGas"
:
21000
"intrinsicGas"
:
"0x5208"
}
}
]
]
\ No newline at end of file
cmd/evm/testdata/17/exp.json
View file @
e761255b
...
@@ -3,13 +3,13 @@
...
@@ -3,13 +3,13 @@
"error"
:
"value exceeds 256 bits"
,
"error"
:
"value exceeds 256 bits"
,
"address"
:
"0xa94f5374fce5edbc8e2a8697c15331677e6ebf0b"
,
"address"
:
"0xa94f5374fce5edbc8e2a8697c15331677e6ebf0b"
,
"hash"
:
"0xfbd91685dcbf8172f0e8c53e2ddbb4d26707840da6b51a74371f62a33868fd82"
,
"hash"
:
"0xfbd91685dcbf8172f0e8c53e2ddbb4d26707840da6b51a74371f62a33868fd82"
,
"intrinsicGas"
:
21000
"intrinsicGas"
:
"0x5208"
},
},
{
{
"error"
:
"gasPrice exceeds 256 bits"
,
"error"
:
"gasPrice exceeds 256 bits"
,
"address"
:
"0x1b57ccef1fe5fb73f1e64530fb4ebd9cf1655964"
,
"address"
:
"0x1b57ccef1fe5fb73f1e64530fb4ebd9cf1655964"
,
"hash"
:
"0x45dc05035cada83748e4c1fe617220106b331eca054f44c2304d5654a9fb29d5"
,
"hash"
:
"0x45dc05035cada83748e4c1fe617220106b331eca054f44c2304d5654a9fb29d5"
,
"intrinsicGas"
:
21000
"intrinsicGas"
:
"0x5208"
},
},
{
{
"error"
:
"invalid transaction v, r, s values"
,
"error"
:
"invalid transaction v, r, s values"
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment