Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.Sign up
net/http: backport "multipart ReadForm close file after copy" to 1.7 #17965
If we do another release of Go 1.7, back port:
Reportedly, it closes a potential DoS vector, exhausting a server's file descriptors.
…copy Always close the file regardless of whether the copy succeeds or fails. Pass along the close error if the copy succeeds Updates #16296 Fixes #17965 Change-Id: Ib394655b91d25750f029f17b3846d985f673fb50 Reviewed-on: https://go-review.googlesource.com/30410 Reviewed-by: Brad Fitzpatrick <firstname.lastname@example.org> Run-TryBot: Brad Fitzpatrick <email@example.com> TryBot-Result: Gobot Gobot <firstname.lastname@example.org> Reviewed-on: https://go-review.googlesource.com/33639 Reviewed-by: Chris Broadfoot <email@example.com> Reviewed-by: Ian Lance Taylor <firstname.lastname@example.org>