aboutsummaryrefslogtreecommitdiffstats
path: root/light
diff options
context:
space:
mode:
authorrjl493456442 <garyrong0905@gmail.com>2018-05-10 15:04:45 +0800
committerPéter Szilágyi <peterke@gmail.com>2018-05-18 16:46:44 +0800
commita2e43d28d01ef9642c7f6992b78b86bd0696c847 (patch)
tree2f5d3444071125e84155321db6fd79d941cfee0b /light
parent6286c255f16a914b39ffd3389cba154a53e66a13 (diff)
downloadgo-tangerine-a2e43d28d01ef9642c7f6992b78b86bd0696c847.tar
go-tangerine-a2e43d28d01ef9642c7f6992b78b86bd0696c847.tar.gz
go-tangerine-a2e43d28d01ef9642c7f6992b78b86bd0696c847.tar.bz2
go-tangerine-a2e43d28d01ef9642c7f6992b78b86bd0696c847.tar.lz
go-tangerine-a2e43d28d01ef9642c7f6992b78b86bd0696c847.tar.xz
go-tangerine-a2e43d28d01ef9642c7f6992b78b86bd0696c847.tar.zst
go-tangerine-a2e43d28d01ef9642c7f6992b78b86bd0696c847.zip
all: collate new transaction events together
Diffstat (limited to 'light')
-rw-r--r--light/txpool.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/light/txpool.go b/light/txpool.go
index 94c8139cb..bedfd48a2 100644
--- a/light/txpool.go
+++ b/light/txpool.go
@@ -321,9 +321,9 @@ func (pool *TxPool) Stop() {
log.Info("Transaction pool stopped")
}
-// SubscribeTxPreEvent registers a subscription of core.TxPreEvent and
+// SubscribeTxPreEvent registers a subscription of core.TxsPreEvent and
// starts sending event to the given channel.
-func (pool *TxPool) SubscribeTxPreEvent(ch chan<- core.TxPreEvent) event.Subscription {
+func (pool *TxPool) SubscribeTxPreEvent(ch chan<- core.TxsPreEvent) event.Subscription {
return pool.scope.Track(pool.txFeed.Subscribe(ch))
}
@@ -412,7 +412,7 @@ func (self *TxPool) add(ctx context.Context, tx *types.Transaction) error {
// Notify the subscribers. This event is posted in a goroutine
// because it's possible that somewhere during the post "Remove transaction"
// gets called which will then wait for the global tx pool lock and deadlock.
- go self.txFeed.Send(core.TxPreEvent{Tx: tx})
+ go self.txFeed.Send(core.TxsPreEvent{types.Transactions{tx}})
}
// Print a log message if low enough level is set