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
66c3eb2f
Unverified
Commit
66c3eb2f
authored
Oct 12, 2020
by
mr_franklin
Committed by
GitHub
Oct 12, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
accouts, consensus, core: fix some comments (#21617)
parent
86dd0055
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
7 additions
and
7 deletions
+7
-7
accounts.go
accounts/accounts.go
+1
-1
wallet.go
accounts/scwallet/wallet.go
+1
-1
wallet.go
accounts/usbwallet/wallet.go
+1
-1
snapshot_test.go
consensus/clique/snapshot_test.go
+1
-1
state_object.go
core/state/state_object.go
+3
-3
No files found.
accounts/accounts.go
View file @
66c3eb2f
...
@@ -88,7 +88,7 @@ type Wallet interface {
...
@@ -88,7 +88,7 @@ type Wallet interface {
// to discover non zero accounts and automatically add them to list of tracked
// to discover non zero accounts and automatically add them to list of tracked
// accounts.
// accounts.
//
//
// Note, self derivaton will increment the last component of the specified path
// Note, self derivat
i
on will increment the last component of the specified path
// opposed to decending into a child path to allow discovering accounts starting
// opposed to decending into a child path to allow discovering accounts starting
// from non zero components.
// from non zero components.
//
//
...
...
accounts/scwallet/wallet.go
View file @
66c3eb2f
...
@@ -637,7 +637,7 @@ func (w *Wallet) Derive(path accounts.DerivationPath, pin bool) (accounts.Accoun
...
@@ -637,7 +637,7 @@ func (w *Wallet) Derive(path accounts.DerivationPath, pin bool) (accounts.Accoun
// to discover non zero accounts and automatically add them to list of tracked
// to discover non zero accounts and automatically add them to list of tracked
// accounts.
// accounts.
//
//
// Note, self derivaton will increment the last component of the specified path
// Note, self derivat
i
on will increment the last component of the specified path
// opposed to decending into a child path to allow discovering accounts starting
// opposed to decending into a child path to allow discovering accounts starting
// from non zero components.
// from non zero components.
//
//
...
...
accounts/usbwallet/wallet.go
View file @
66c3eb2f
...
@@ -493,7 +493,7 @@ func (w *wallet) Derive(path accounts.DerivationPath, pin bool) (accounts.Accoun
...
@@ -493,7 +493,7 @@ func (w *wallet) Derive(path accounts.DerivationPath, pin bool) (accounts.Accoun
// to discover non zero accounts and automatically add them to list of tracked
// to discover non zero accounts and automatically add them to list of tracked
// accounts.
// accounts.
//
//
// Note, self derivaton will increment the last component of the specified path
// Note, self derivat
i
on will increment the last component of the specified path
// opposed to decending into a child path to allow discovering accounts starting
// opposed to decending into a child path to allow discovering accounts starting
// from non zero components.
// from non zero components.
//
//
...
...
consensus/clique/snapshot_test.go
View file @
66c3eb2f
...
@@ -423,7 +423,7 @@ func TestClique(t *testing.T) {
...
@@ -423,7 +423,7 @@ func TestClique(t *testing.T) {
})
})
// Iterate through the blocks and seal them individually
// Iterate through the blocks and seal them individually
for
j
,
block
:=
range
blocks
{
for
j
,
block
:=
range
blocks
{
// Get
h
the header and prepare it for signing
// Get the header and prepare it for signing
header
:=
block
.
Header
()
header
:=
block
.
Header
()
if
j
>
0
{
if
j
>
0
{
header
.
ParentHash
=
blocks
[
j
-
1
]
.
Hash
()
header
.
ParentHash
=
blocks
[
j
-
1
]
.
Hash
()
...
...
core/state/state_object.go
View file @
66c3eb2f
...
@@ -299,7 +299,7 @@ func (s *stateObject) updateTrie(db Database) Trie {
...
@@ -299,7 +299,7 @@ func (s *stateObject) updateTrie(db Database) Trie {
if
len
(
s
.
pendingStorage
)
==
0
{
if
len
(
s
.
pendingStorage
)
==
0
{
return
s
.
trie
return
s
.
trie
}
}
// Track the amount of time wasted on updating the storge trie
// Track the amount of time wasted on updating the stor
a
ge trie
if
metrics
.
EnabledExpensive
{
if
metrics
.
EnabledExpensive
{
defer
func
(
start
time
.
Time
)
{
s
.
db
.
StorageUpdates
+=
time
.
Since
(
start
)
}(
time
.
Now
())
defer
func
(
start
time
.
Time
)
{
s
.
db
.
StorageUpdates
+=
time
.
Since
(
start
)
}(
time
.
Now
())
}
}
...
@@ -347,7 +347,7 @@ func (s *stateObject) updateRoot(db Database) {
...
@@ -347,7 +347,7 @@ func (s *stateObject) updateRoot(db Database) {
if
s
.
updateTrie
(
db
)
==
nil
{
if
s
.
updateTrie
(
db
)
==
nil
{
return
return
}
}
// Track the amount of time wasted on hashing the storge trie
// Track the amount of time wasted on hashing the stor
a
ge trie
if
metrics
.
EnabledExpensive
{
if
metrics
.
EnabledExpensive
{
defer
func
(
start
time
.
Time
)
{
s
.
db
.
StorageHashes
+=
time
.
Since
(
start
)
}(
time
.
Now
())
defer
func
(
start
time
.
Time
)
{
s
.
db
.
StorageHashes
+=
time
.
Since
(
start
)
}(
time
.
Now
())
}
}
...
@@ -364,7 +364,7 @@ func (s *stateObject) CommitTrie(db Database) error {
...
@@ -364,7 +364,7 @@ func (s *stateObject) CommitTrie(db Database) error {
if
s
.
dbErr
!=
nil
{
if
s
.
dbErr
!=
nil
{
return
s
.
dbErr
return
s
.
dbErr
}
}
// Track the amount of time wasted on committing the storge trie
// Track the amount of time wasted on committing the stor
a
ge trie
if
metrics
.
EnabledExpensive
{
if
metrics
.
EnabledExpensive
{
defer
func
(
start
time
.
Time
)
{
s
.
db
.
StorageCommits
+=
time
.
Since
(
start
)
}(
time
.
Now
())
defer
func
(
start
time
.
Time
)
{
s
.
db
.
StorageCommits
+=
time
.
Since
(
start
)
}(
time
.
Now
())
}
}
...
...
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