Skip to content

Commit

Permalink
fix: Remove tx rollback from the reorg handler (#55)
Browse files Browse the repository at this point in the history
  • Loading branch information
rbpol authored Sep 5, 2024
1 parent 094ed72 commit 8730a8e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion l1infotreesync/processor.go
Original file line number Diff line number Diff line change
Expand Up @@ -278,12 +278,13 @@ func (p *processor) Reorg(ctx context.Context, firstReorgedBlock uint64) error {
if err != nil {
return err
}
defer tx.Rollback()

c, err := tx.Cursor(blockTable)
if err != nil {
return err
}
defer c.Close()

firstKey := common.Uint64ToBytes(firstReorgedBlock)
firstReorgedL1InfoTreeIndex := int64(-1)
for blkKey, blkValue, err := c.Seek(firstKey); blkKey != nil; blkKey, blkValue, err = c.Next() {
Expand Down

0 comments on commit 8730a8e

Please sign in to comment.