From 76f51fa545c03c6efc79d7efa84c6a27e3b5e5e8 Mon Sep 17 00:00:00 2001 From: Jacob Casper Date: Fri, 17 Apr 2020 11:00:12 -0500 Subject: [PATCH] Avoid fd limits by closing body immediately --- backend/scrape/graph/graph.go | 1 + 1 file changed, 1 insertion(+) diff --git a/backend/scrape/graph/graph.go b/backend/scrape/graph/graph.go index cc1dc1e..d043209 100644 --- a/backend/scrape/graph/graph.go +++ b/backend/scrape/graph/graph.go @@ -62,6 +62,7 @@ SELECT EXISTS ( } resp, err := http.PostForm("http://localhost:8080/artist/add", url.Values{"id": {string(artist.ID)}}) + resp.Body.Close() if err != nil { log.Print(err) success = false -- 2.20.1