Skip to content

Commit

Permalink
eth/filters: use buffered channel to avoid goroutine leak (ethereum#2…
Browse files Browse the repository at this point in the history
  • Loading branch information
BurtonQin authored May 30, 2022
1 parent 2140aab commit 03157b6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion eth/filters/filter_system_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -592,7 +592,7 @@ func TestPendingLogsSubscription(t *testing.T) {
// (some) events are posted.
for i := range testCases {
testCases[i].c = make(chan []*types.Log)
testCases[i].err = make(chan error)
testCases[i].err = make(chan error, 1)

var err error
testCases[i].sub, err = api.events.SubscribeLogs(testCases[i].crit, testCases[i].c)
Expand Down

0 comments on commit 03157b6

Please sign in to comment.