src/Pcntl/Thread.php
public function stop($signal = SIGKILL, $wait = false)
    {
        if ($this->isAlive()) {
            posix_kill($this->_pid, $signal);
            if ($wait) {
                pcntl_waitpid($this->_pid, $status = 0);
            }
        }
    }
public function stop($signal = SIGKILL, $wait = false)
    {
        if ($this->isAlive()) {
            posix_kill($this->_pid, $signal);
            if ($wait) {
                pcntl_waitpid($this->_pid, $status = 0);
            }
        }
    }
public function stop ( $ signal = SIGKILL , $ wait = false ) { if ( $ this -> isAlive ( ) ) { posix_kill ( $ this -> _pid , $ signal ) ; if ( $ wait ) { pcntl_waitpid ( $ this -> _pid , $ status = 0 ) ; } } }
Attempts to stop the thread
returns true on success and false otherwise

@param integer $signal SIGKILL or SIGTERM
@param boolean $wait Wait until child has exited

@return void
Attempts to stop the thread returns true on success and false otherwise