File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -75,18 +75,18 @@ func (p *Peer) broadcastTransactions() {
75
75
if done == nil && len (queue ) > 0 {
76
76
// Pile transaction until we reach our allowed network limit
77
77
var (
78
- hashes []common. Hash
79
- txs []* types.Transaction
80
- size common.StorageSize
78
+ hashesCount uint64
79
+ txs []* types.Transaction
80
+ size common.StorageSize
81
81
)
82
82
for i := 0 ; i < len (queue ) && size < maxTxPacketSize ; i ++ {
83
83
if tx := p .txpool .Get (queue [i ]); tx != nil {
84
84
txs = append (txs , tx )
85
85
size += tx .Size ()
86
86
}
87
- hashes = append ( hashes , queue [ i ])
87
+ hashesCount ++
88
88
}
89
- queue = queue [:copy (queue , queue [len ( hashes ) :])]
89
+ queue = queue [:copy (queue , queue [hashesCount :])]
90
90
91
91
// If there's anything available to transfer, fire up an async writer
92
92
if len (txs ) > 0 {
You can’t perform that action at this time.
0 commit comments