Skip to content

Commit ff5f457

Browse files
authored
Merge pull request #425 from SiaFoundation/nate/v2-pool-index
Fix pool index
2 parents 74944b2 + 780b533 commit ff5f457

2 files changed

Lines changed: 6 additions & 1 deletion

File tree

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
default: patch
3+
---
4+
5+
# Fix incorrect v2 pool index.

chain/manager.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1419,7 +1419,7 @@ func (m *Manager) AddV2PoolTransactions(basis types.ChainIndex, txns []types.V2T
14191419
return false, fmt.Errorf("transaction %v conflicts with pool: %w", txid, err)
14201420
}
14211421
m.txpool.ms.ApplyV2Transaction(txn)
1422-
m.txpool.indices[txid] = len(m.txpool.txns)
1422+
m.txpool.indices[txid] = len(m.txpool.v2txns)
14231423
m.txpool.v2txns = append(m.txpool.v2txns, txn)
14241424
m.txpool.weight += m.tipState.V2TransactionWeight(txn)
14251425
}

0 commit comments

Comments
 (0)