Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

support non-clean shutdown #155

Merged
merged 17 commits into from
Sep 1, 2022
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fix deadlock in FindRetentionBound
  • Loading branch information
tsahee committed Aug 30, 2022
commit 57a6751e61085828edf859dbf396c5b5e3feafff
2 changes: 1 addition & 1 deletion core/blockchain_arbitrum.go
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ func (bc *BlockChain) FindRetentionBound() uint64 {
//
a := timeBound // a prunable block, if possible
b := heightBound // not prunable
for a+1 < b {
for a+2 < b {
mid := a/2 + b/2 // a < mid < b
age := current.Time() - bc.GetBlockByNumber(mid).Time()
if age <= minimumAge {
Expand Down