This commit is contained in:
Zack Scholl 2018-09-26 09:13:11 -07:00
parent 182a9fe2f4
commit 1954691f44
1 changed files with 1 additions and 1 deletions

View File

@ -136,7 +136,7 @@ func chanFromConn(conn net.Conn) chan []byte {
b := make([]byte, models.TCP_BUFFER_SIZE)
n, err := reader.Read(b)
if n > 0 {
c <- b
c <- b[:n]
// res := make([]byte, n)
// // Copy the buffer so it doesn't get changed while read by the recipient.
// copy(res, b[:n])