rafthttp: log stream stopped message before closing channel

Was causing spurious goroutine leak failures in testing.
This commit is contained in:
Anthony Romano 2016-09-09 12:47:06 -07:00
parent aa6b1e6a10
commit 0250f0c984

View File

@ -320,8 +320,8 @@ func (cr *streamReader) run() {
// overhead when retry.
case <-time.After(100 * time.Millisecond):
case <-cr.stopc:
close(cr.done)
plog.Infof("stopped streaming with peer %s (%s reader)", cr.peerID, t)
close(cr.done)
return
}
}