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
a75c0610
Unverified
Commit
a75c0610
authored
Mar 23, 2020
by
meowsbits
Committed by
GitHub
Mar 23, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
core/blockchain: simplify atomic store after writeBlockWithState (#20798)
Signed-off-by:
meows
<
b5c6@protonmail.com
>
parent
613af7ce
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
2 deletions
+1
-2
blockchain.go
core/blockchain.go
+1
-2
No files found.
core/blockchain.go
View file @
a75c0610
...
@@ -1740,11 +1740,10 @@ func (bc *BlockChain) insertChain(chain types.Blocks, verifySeals bool) (int, er
...
@@ -1740,11 +1740,10 @@ func (bc *BlockChain) insertChain(chain types.Blocks, verifySeals bool) (int, er
// Write the block to the chain and get the status.
// Write the block to the chain and get the status.
substart
=
time
.
Now
()
substart
=
time
.
Now
()
status
,
err
:=
bc
.
writeBlockWithState
(
block
,
receipts
,
logs
,
statedb
,
false
)
status
,
err
:=
bc
.
writeBlockWithState
(
block
,
receipts
,
logs
,
statedb
,
false
)
atomic
.
StoreUint32
(
&
followupInterrupt
,
1
)
if
err
!=
nil
{
if
err
!=
nil
{
atomic
.
StoreUint32
(
&
followupInterrupt
,
1
)
return
it
.
index
,
err
return
it
.
index
,
err
}
}
atomic
.
StoreUint32
(
&
followupInterrupt
,
1
)
// Update the metrics touched during block commit
// Update the metrics touched during block commit
accountCommitTimer
.
Update
(
statedb
.
AccountCommits
)
// Account commits are complete, we can mark them
accountCommitTimer
.
Update
(
statedb
.
AccountCommits
)
// Account commits are complete, we can mark them
...
...
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