Skip to content

Commit

Permalink
馃崪slightly revise
Browse files Browse the repository at this point in the history
  • Loading branch information
panjf2000 committed Jul 27, 2019
1 parent 9476326 commit 61c6b5a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion worker.go
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ func (w *Worker) run() {
}()

for f := range w.task {
if nil == f {
if f == nil {
w.pool.decRunning()
w.pool.workerCache.Put(w)
return
Expand Down
2 changes: 1 addition & 1 deletion worker_func.go
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ func (w *WorkerWithFunc) run() {
}()

for args := range w.args {
if nil == args {
if args == nil {
w.pool.decRunning()
w.pool.workerCache.Put(w)
return
Expand Down

0 comments on commit 61c6b5a

Please sign in to comment.