aboutsummaryrefslogtreecommitdiffstats
path: root/modules/queue/queue_bytefifo.go
diff options
context:
space:
mode:
Diffstat (limited to 'modules/queue/queue_bytefifo.go')
-rw-r--r--modules/queue/queue_bytefifo.go5
1 files changed, 4 insertions, 1 deletions
diff --git a/modules/queue/queue_bytefifo.go b/modules/queue/queue_bytefifo.go
index 7f2acf3deb..bf153d70bb 100644
--- a/modules/queue/queue_bytefifo.go
+++ b/modules/queue/queue_bytefifo.go
@@ -205,7 +205,10 @@ loop:
// tell the pool to shutdown.
q.baseCtxCancel()
return
- case data := <-q.dataChan:
+ case data, ok := <-q.dataChan:
+ if !ok {
+ return
+ }
if err := q.PushBack(data); err != nil {
log.Error("Unable to push back data into queue %s", q.name)
}