From 726e763c46b9a775a8596056d55092fe7f2803ea Mon Sep 17 00:00:00 2001 From: Matt Joiner Date: Tue, 3 May 2016 14:58:26 +1000 Subject: [PATCH] Doc and logging improvements --- client.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/client.go b/client.go index eae9d94e..fd5aeabe 100644 --- a/client.go +++ b/client.go @@ -59,7 +59,7 @@ func (cl *Client) queueFirstHash(t *Torrent, piece int) { cl.queuePieceCheck(t, piece) } -// Clients contain zero or more Torrents. A client manages a blocklist, the +// Clients contain zero or more Torrents. A Client manages a blocklist, the // TCP/UDP protocol ports, and DHT as desired. type Client struct { halfOpenLimit int @@ -1012,7 +1012,7 @@ func (cl *Client) completedMetadata(t *Torrent) { var ih metainfo.Hash missinggo.CopyExact(&ih, h.Sum(nil)) if ih != t.infoHash { - log.Print("bad metadata") + log.Printf("torrent %q: metadata bytes failed hash check", t) t.invalidateMetadata() return }