Skip to content

Commit 3b62ca2

Browse files
Marcel GebhardtMarcel Gebhardt
authored andcommitted
fix: do not read response body after successful authentication
1 parent 428a29c commit 3b62ca2

File tree

1 file changed

+0
-6
lines changed

1 file changed

+0
-6
lines changed

ntlm.go

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -103,12 +103,6 @@ func WrapDialContext(dialContext DialContext, proxyAddress, proxyUsername, proxy
103103
debugf("ntlm> Could not read response from proxy: %s", err)
104104
return conn, err
105105
}
106-
_, err = ioutil.ReadAll(resp.Body)
107-
if err != nil {
108-
debugf("ntlm> Could not read response body from proxy: %s", err)
109-
return conn, err
110-
}
111-
resp.Body.Close()
112106
if resp.StatusCode != http.StatusOK {
113107
debugf("ntlm> Expected %d as return status, got: %d", http.StatusOK, resp.StatusCode)
114108
return conn, errors.New(http.StatusText(resp.StatusCode))

0 commit comments

Comments
 (0)