Commit fd8e2b3a authored by Brian Tiger Chow's avatar Brian Tiger Chow Committed by Jeromy

fix(bitswap) stop the ticker when the run loop exits

@whyrusleeping

License: MIT
Signed-off-by: default avatarBrian Tiger Chow <brian@perfmode.com>
parent 2a4a6d3e
......@@ -170,6 +170,7 @@ func (bs *bitswap) run(ctx context.Context) {
rebroadcastTime := time.Second * 5
broadcastSignal := time.NewTicker(bs.strategy.GetRebroadcastDelay())
defer broadcastSignal.Stop()
for {
select {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment