Unverified Commit 521cd9ea authored by Steven Allen's avatar Steven Allen Committed by GitHub
Browse files

Merge pull request #408 from libp2p/dont-disable-logging

use the new DisableLogging mdns option, don't turn off logging globally
Showing with 7 additions and 7 deletions
+7 -7
......@@ -4,8 +4,6 @@ import (
"context"
"errors"
"io"
"io/ioutil"
golog "log"
"net"
"sync"
"time"
......@@ -19,6 +17,11 @@ import (
"github.com/whyrusleeping/mdns"
)
func init() {
// don't let mdns use logging...
mdns.DisableLogging = true
}
var log = logging.Logger("mdns")
const ServiceTag = "_ipfs-discovery._udp"
......@@ -64,9 +67,6 @@ func getDialableListenAddrs(ph host.Host) ([]*net.TCPAddr, error) {
func NewMdnsService(ctx context.Context, peerhost host.Host, interval time.Duration, serviceTag string) (Service, error) {
// TODO: dont let mdns use logging...
golog.SetOutput(ioutil.Discard)
var ipaddrs []net.IP
port := 4001
......
......@@ -14,9 +14,9 @@
"version": "0.0.0"
},
{
"hash": "QmNeRzgrSpwbMU7VKLRyfvbqf1nRrAiQ7fEXaBxWGT5Ygr",
"hash": "QmekaTKpWkYGcn4ZEC5PwJDRCQHapwugmmG86g2Xpz5GBH",
"name": "mdns",
"version": "0.1.3"
"version": "0.2.0"
},
{
"hash": "QmPdKqUcHGFdeSpvjVoaTRPPstGif9GBZb5Q56RVw9o69A",
......
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