reverse the arguments to io.Copy so the destination is on the

left, like an assignment, like strcpy, etc.

R=rsc
CC=go-dev
http://go/go-review/1016011
This commit is contained in:
Rob Pike 2009-11-01 20:59:49 -08:00
parent 4e5296d4ba
commit 4d310f2434
19 changed files with 38 additions and 38 deletions

View file

@ -71,7 +71,7 @@ func exec(c *http.Conn, args []string) (status int) {
}
var buf bytes.Buffer;
io.Copy(r, &buf);
io.Copy(&buf, r);
wait, err := os.Wait(pid, 0);
if err != nil {
os.Stderr.Write(buf.Bytes());