From 4241241031cdad175ff8d7b0f6ef7502912b04af Mon Sep 17 00:00:00 2001 From: vyzo Date: Sat, 13 Jan 2018 12:24:31 +0200 Subject: [PATCH] fix dangling maxConcurrency reference --- floodsub.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/floodsub.go b/floodsub.go index 70a207c..1664418 100644 --- a/floodsub.go +++ b/floodsub.go @@ -116,7 +116,7 @@ func NewFloodSub(ctx context.Context, h host.Host, opts ...Option) (*PubSub, err peers: make(map[peer.ID]chan *RPC), seenMessages: timecache.NewTimeCache(time.Second * 30), counter: uint64(time.Now().UnixNano()), - throttleValidate: make(chan struct{}, maxConcurrency), + throttleValidate: make(chan struct{}, defaultMaxConcurrency), } for _, opt := range opts {