crowdmob/goamz — pull request #143 by johannac (2014-06-05 14:30:35+00:00)
Title: Fix File I/O Leak

This fixes a bug where the http.Response body (which is an io.ReadCloser) is left open. If you call to the run() function, it will only close the http.Response.Body only if the second function parameter 'resp' is not nil. Otherwise its returned and the caller must close it. However, the query() function ignores the returned http.Response.Body by assigning to _, so the io reader is left open. If several requests per second are sent, this can cause io flood warnings like 'too many open files'.