webserver.php
changeset 67 c4aefad02ce4
parent 64 ee64bb096f56
child 68 32f6e2ee15ab
equal deleted inserted replaced
66:f30ffbf92cdd 67:c4aefad02ce4
   349    * Destructor.
   349    * Destructor.
   350    */
   350    */
   351   
   351   
   352   function __destruct()
   352   function __destruct()
   353   {
   353   {
       
   354     if ( !is_object($this->threader) )
       
   355     {
       
   356       return false;
       
   357     }
   354     if ( !$this->threader->is_child() && $this->socket_initted )
   358     if ( !$this->threader->is_child() && $this->socket_initted )
   355     {
   359     {
   356       if ( function_exists('status') )
   360       if ( function_exists('status') )
   357         status('WebServer: destroying socket');
   361         status('WebServer: destroying socket');
   358       $this->server->destroy();
   362       $this->server->destroy();