Switch bool chan to struct chan for less memory usage

This commit is contained in:
Chris Bednarski 2015-10-12 22:04:13 -07:00
parent 445595c6b5
commit a4eba1102b
1 changed files with 2 additions and 2 deletions

View File

@ -139,10 +139,10 @@ func (c *communicator) Download(path string, w io.Writer) (err error) {
// Serve a single connection and a single copy
streamId := c.mux.NextId()
waitServer := make(chan bool)
waitServer := make(chan struct{})
go func() {
serveSingleCopy("downloadWriter", c.mux, streamId, w, nil)
waitServer <- true
close(waitServer)
}()
args := CommunicatorDownloadArgs{