• Nigel Tao's avatar
    bufio: make Writer.ReadFrom not flush prematurely. For example, · e55fdff2
    Nigel Tao authored
    many small writes to a network may be less efficient that a few
    large writes.
    
    This fixes net/http's TestClientWrites, broken by 6565056 that
    introduced Writer.ReadFrom. That test implicitly assumed that
    calling io.Copy on a *bufio.Writer wouldn't write to the
    underlying network until the buffer was full.
    
    R=dsymonds
    CC=bradfitz, golang-dev, mchaten, mikioh.mikioh
    https://golang.org/cl/6743044
    e55fdff2
bufio.go 14.2 KB