From cf55055d12e8894e54947389d6f2e6e1af91db65 Mon Sep 17 00:00:00 2001
From: Matt Joiner <anacrolix@gmail.com>
Date: Tue, 17 May 2016 02:12:06 +1000
Subject: [PATCH] Improve the note about chunk writing concurrency

Everytime I see memory spike I suspect this, and it isn't it.
---
 client.go | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/client.go b/client.go
index c92f7c2c..44298663 100644
--- a/client.go
+++ b/client.go
@@ -1816,7 +1816,8 @@ func (cl *Client) downloadedChunk(t *Torrent, c *connection, msg *pp.Message) {
 	}
 
 	cl.mu.Unlock()
-	// Write the chunk out.
+	// Write the chunk out. Note that the upper bound on chunk writing
+	// concurrency will be the number of connections.
 	err := t.writeChunk(int(msg.Index), int64(msg.Begin), msg.Piece)
 	cl.mu.Lock()
 
-- 
2.51.0