diff --git a/dev/http.go b/dev/http.go index 7726719..2f8f61c 100644 --- a/dev/http.go +++ b/dev/http.go @@ -170,6 +170,7 @@ func (h *HTTPServer) ServeHTTP(w http.ResponseWriter, req *http.Request) { fi, err := os.Stat(path) if err == nil && !fi.IsDir() { if ofile, err := os.Open(path); err == nil { + defer ofile.Close() http.ServeContent(w, req, req.URL.Path, fi.ModTime(), io.ReadSeeker(ofile)) return }