Skip to content
This repository was archived by the owner on Feb 19, 2025. It is now read-only.

Commit 610850e

Browse files
authored
Merge pull request #41 from cloudflare/bugfix/deadlock
Fix for #40: change the position of the channel
2 parents b521287 + 7719533 commit 610850e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

decoders/decoder.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,11 +39,11 @@ func (w Worker) Start() {
3939
go func() {
4040
//log.Debugf("Worker %v started", w.Id)
4141
for {
42-
w.WorkerPool <- w.InMsg
4342
select {
4443
case <-w.Quit:
4544
break
46-
case msg := <-w.InMsg:
45+
case w.WorkerPool <- w.InMsg:
46+
msg := <-w.InMsg
4747
timeTrackStart := time.Now()
4848
err := w.DecoderParams.DecoderFunc(msg)
4949
timeTrackStop := time.Now()

0 commit comments

Comments
 (0)