]> Cypherpunks repositories - gostls13.git/commitdiff
net/http: don't ignore Request.Write's Flush error
authorBrad Fitzpatrick <bradfitz@golang.org>
Thu, 12 Jan 2012 21:15:40 +0000 (13:15 -0800)
committerBrad Fitzpatrick <bradfitz@golang.org>
Thu, 12 Jan 2012 21:15:40 +0000 (13:15 -0800)
Pointed out by nekotaroh in issue 2645

R=golang-dev, gri
CC=golang-dev
https://golang.org/cl/5539045

src/pkg/net/http/request.go

index 66178490e37b80dfb8e427ab30eafe39b2539d91..260301005ebb13374b7ef082abe4f0aa81308855 100644 (file)
@@ -368,8 +368,8 @@ func (req *Request) write(w io.Writer, usingProxy bool, extraHeaders Header) err
        if err != nil {
                return err
        }
-       bw.Flush()
-       return nil
+
+       return bw.Flush()
 }
 
 // Convert decimal at s[i:len(s)] to integer,