fix(tea): allocate msgs channel in constructor
Before adoption: this commit came in with the history the project adopted, so no landing records it.
Race condition bug: Start() is called in a new gorotuine, then Send(). If the Send happens before the msgs channel is allocated, the message is dropped. Instead allocate the channel in the constructor, so msgs is never nil.
authored by Christian Stewart · committed by Christian Rocha · parent 66cea09 · Browse files · 1 file+2 added−5 removed
This commit
State
Before adoption: this commit came in with the history the project adopted, so no landing records it.
Trailers
- Signed-off-by: Christian Stewart <christian@paral.in>
Diff stats
1 file+2 added−5 removed
- other:+2 added−5 removed