fix: Fix slice index bug

This commit is contained in:
healthykim 2025-07-14 13:43:20 +02:00
parent 3f9e1229ea
commit 8a8fef540a

View file

@ -439,8 +439,8 @@ func (f *TxFetcher) loop() {
if want > maxTxAnnounces {
txAnnounceDOSMeter.Mark(int64(want - maxTxAnnounces))
ann.hashes = ann.hashes[:want-maxTxAnnounces]
ann.metas = ann.metas[:want-maxTxAnnounces]
ann.hashes = ann.hashes[:maxTxAnnounces-used]
ann.metas = ann.metas[:maxTxAnnounces-used]
}
// All is well, schedule the remainder of the transactions
var (