Skip to content

Commit

Permalink
sync finalization
Browse files Browse the repository at this point in the history
  • Loading branch information
randomlogin committed Mar 24, 2024
1 parent e1bf461 commit 924961a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion sync/hnsd.go
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,7 @@ func parseAndWriteOutput(stdoutPipe io.ReadCloser, signalChannel chan os.Signal,
treeRoot := match[2]

// if there's a tempBlock already, add it to the slidingWindow
if tempBlock != nil {
if tempBlock != nil && !contains(slidingWindow, tempBlock.TreeRoot) {
slidingWindow = append(slidingWindow, *tempBlock)
if len(slidingWindow) > BlocksToStore {
slidingWindow = slidingWindow[1:]
Expand Down

0 comments on commit 924961a

Please sign in to comment.