Unverified Commit 2bfd9a28 authored by zhaochonghe's avatar zhaochonghe Committed by GitHub

core: fix the order of address in queue (#24907)

reverse the order of address in queue
parent 7bcbbbf8
......@@ -1476,7 +1476,7 @@ func (pool *TxPool) truncateQueue() {
addresses = append(addresses, addressByHeartbeat{addr, pool.beats[addr]})
}
}
sort.Sort(addresses)
sort.Sort(sort.Reverse(addresses))
// Drop transactions until the total is below the limit or only locals remain
for drop := queued - pool.config.GlobalQueue; drop > 0 && len(addresses) > 0; {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment