send mutex
This commit is contained in:
parent
c7c9a52850
commit
5d8d892185
@ -34,6 +34,9 @@ func (p *Provider) RoundTrip(ctx context.Context) {
|
||||
return
|
||||
}
|
||||
|
||||
p.txPool.ExclusiveSend.Lock()
|
||||
defer p.txPool.ExclusiveSend.Unlock()
|
||||
|
||||
txHash := common.Hash{}
|
||||
attempt := 0
|
||||
nonce := uint64(0)
|
||||
|
@ -18,6 +18,8 @@ type NetworkTransactionPool struct {
|
||||
|
||||
// Last time a transaction was sent
|
||||
LastSend time.Time
|
||||
// Prevents concurrent transaction send
|
||||
ExclusiveSend sync.Mutex
|
||||
}
|
||||
|
||||
type TransactionState struct {
|
||||
|
Loading…
Reference in New Issue
Block a user