diff options
author | Wolfy-J <[email protected]> | 2018-06-05 23:32:41 +0300 |
---|---|---|
committer | Wolfy-J <[email protected]> | 2018-06-05 23:32:41 +0300 |
commit | f762cd2bff2fa35e32bc4502c97d2ee0984397b7 (patch) | |
tree | 648e77366d775baec7e4fbef142bb6554911c887 /static_pool.go | |
parent | 678a7c4ed8ab74a0e391a76da0ffb92dd997c56e (diff) |
thread safe buffer for worker errors
Diffstat (limited to 'static_pool.go')
-rw-r--r-- | static_pool.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/static_pool.go b/static_pool.go index cc2b38ab..07c71c46 100644 --- a/static_pool.go +++ b/static_pool.go @@ -203,7 +203,7 @@ func (p *StaticPool) createWorker() (*Worker, error) { err := w.Wait() // worker have died unexpectedly, pool should attempt to replace it with alive version safely - if w.state.Value() != StateStopped { + if w.state.Value() == StateErrored { if err != nil { p.throw(EventWorkerError, WorkerError{Worker: w, Caused: err}) } |