Commit ee3c3070 authored by Jeromy Johnson's avatar Jeromy Johnson

Merge pull request #1174 from ipfs/fix/mdns-panic

hotfix: dont use nodes context because it might not be set yet
parents cc5f6bb3 9e6866f5
......@@ -292,7 +292,7 @@ func setupDiscoveryOption(d config.Discovery) DiscoveryOption {
func (n *IpfsNode) HandlePeerFound(p peer.PeerInfo) {
log.Warning("trying peer info: ", p)
ctx, _ := context.WithTimeout(n.Context(), time.Second*10)
ctx, _ := context.WithTimeout(context.TODO(), time.Second*10)
err := n.PeerHost.Connect(ctx, p)
if err != nil {
log.Warning("Failed to connect to peer found by discovery: ", err)
......
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