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
64e2f52c
Commit
64e2f52c
authored
Jul 30, 2015
by
Jeffrey Wilcke
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #1534 from obscuren/issue-1040
rpc: to in eth_call no longer required. Fixed eth_estimateGas
parents
e7f4232b
d261c3f4
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
4 additions
and
8 deletions
+4
-8
args_test.go
rpc/api/args_test.go
+3
-3
eth.go
rpc/api/eth.go
+1
-1
eth_args.go
rpc/api/eth_args.go
+0
-4
No files found.
rpc/api/args_test.go
View file @
64e2f52c
...
...
@@ -935,9 +935,9 @@ func TestCallArgsNotStrings(t *testing.T) {
func
TestCallArgsToEmpty
(
t
*
testing
.
T
)
{
input
:=
`[{"from": "0xb60e8dd61c5d32be8058bb8eb970870f07233155"}]`
args
:=
new
(
CallArgs
)
str
:=
ExpectValidationError
(
json
.
Unmarshal
([]
byte
(
input
),
&
args
)
)
if
len
(
str
)
>
0
{
t
.
Error
(
st
r
)
err
:=
json
.
Unmarshal
([]
byte
(
input
),
&
args
)
if
err
!=
nil
{
t
.
Error
(
"Did not expect error. Got"
,
er
r
)
}
}
...
...
rpc/api/eth.go
View file @
64e2f52c
...
...
@@ -322,7 +322,7 @@ func (self *ethApi) EstimateGas(req *shared.Request) (interface{}, error) {
if
len
(
gas
)
==
0
{
return
newHexNum
(
0
),
nil
}
else
{
return
newHexNum
(
gas
),
nil
return
newHexNum
(
common
.
String2Big
(
gas
)),
err
}
}
...
...
rpc/api/eth_args.go
View file @
64e2f52c
...
...
@@ -469,10 +469,6 @@ func (args *CallArgs) UnmarshalJSON(b []byte) (err error) {
}
args
.
From
=
ext
.
From
if
len
(
ext
.
To
)
==
0
{
return
shared
.
NewValidationError
(
"to"
,
"is required"
)
}
args
.
To
=
ext
.
To
var
num
*
big
.
Int
...
...
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