Improve the log message when piece reads fail

This commit is contained in:
Matt Joiner 2016-07-10 23:01:17 +10:00
parent 363f042b95
commit 9943fc3c58
1 changed files with 1 additions and 1 deletions

View File

@ -177,7 +177,7 @@ func (r *Reader) readOnceAt(b []byte, pos int64, ctxErr *error) (n int, err erro
err = nil
return
}
log.Printf("%s: error reading from torrent storage pos=%d: %s", r.t, pos, err)
log.Printf("error reading torrent %q piece %d offset %d, %d bytes: %s", r.t, pi, po, len(b1), err)
r.t.cl.mu.Lock()
r.t.updateAllPieceCompletions()
r.t.updatePiecePriorities()