Don't count current channel when testing for slowness (#584)

This commit is contained in:
Kaloyan Raev 2018-11-08 09:40:07 +02:00 committed by GitHub
parent 66ee332446
commit 3501d983ec
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -248,7 +248,7 @@ func (er *encodedReader) checkSlowChannel(num int) (closed bool) {
// check how many buffer channels are already empty
ec := 0
for i := range er.eps {
if !er.eps[i].closed && len(er.eps[i].ch) == 0 {
if i != num && !er.eps[i].closed && len(er.eps[i].ch) == 0 {
ec++
}
}