added favicon 404

This commit is contained in:
ston1th 2019-08-03 23:38:17 +02:00
commit dae45986f6
3 changed files with 9 additions and 0 deletions

View file

@ -53,6 +53,9 @@ func main() {
log.Printf("%s %s %s", r.RemoteAddr, r.Method, r.URL)
fmt.Fprintf(w, "api: ok")
})
http.HandleFunc("/favicon.ico", func(w http.ResponseWriter, r *http.Request) {
w.WriteHeader(http.StatusNotFound)
})
s := &http.Server{
ReadTimeout: 5 * time.Second,
WriteTimeout: 10 * time.Second,