This commit is contained in:
Daniil Gentili 2017-05-19 21:34:33 +02:00 committed by GitHub
parent a84c36b60f
commit 3ade409442

View File

@ -64,6 +64,9 @@ if (!extension_loaded('pthreads')) {
private function runCollectable($idx, Collectable $collectable)
{
$collectable->worker = $this;
if (!isset($collectable->state)) {
$collectable->state = 0;
}
$collectable->state |= THREAD::RUNNING;
$collectable->run();
$collectable->state &= ~THREAD::RUNNING;