(thread *phpThread)
| 256 | } |
| 257 | |
| 258 | func (worker *worker) detachThread(thread *phpThread) { |
| 259 | worker.threadMutex.Lock() |
| 260 | for i, t := range worker.threads { |
| 261 | if t == thread { |
| 262 | worker.threads = append(worker.threads[:i], worker.threads[i+1:]...) |
| 263 | break |
| 264 | } |
| 265 | } |
| 266 | worker.threadMutex.Unlock() |
| 267 | } |
| 268 | |
| 269 | func (worker *worker) countThreads() int { |
| 270 | worker.threadMutex.RLock() |
no outgoing calls
no test coverage detected