http: fixed bencoding, compact, added log

This commit is contained in:
Leo Balduf
2016-04-07 22:31:38 -04:00
parent 8a6618f947
commit 6c2ab5170d
3 changed files with 6 additions and 3 deletions

View File

@@ -112,7 +112,10 @@ func (s *httpServer) serveAnnounce(w http.ResponseWriter, r *http.Request, p htt
return
}
writeAnnounceResponse(w, resp)
err = writeAnnounceResponse(w, resp)
if err != nil {
log.Println("error serializing response", err)
}
}
func (s *httpServer) serveScrape(w http.ResponseWriter, r *http.Request, p httprouter.Params) {