Fix :DD (remove temp. feature)

This commit is contained in:
Shoghi Cervantes Pueyo 2013-04-27 00:49:59 +02:00
parent 47e9a7b6a1
commit 2a4d2a92ab

View File

@ -267,7 +267,7 @@ class ConsoleLoop extends Thread{
public function run(){ public function run(){
$fp = fopen("php://stdin", "r"); $fp = fopen("php://stdin", "r");
if(HAS_EVENT){ if(HAS_EVENT and false){
$this->base = new EventBase(); $this->base = new EventBase();
$this->ev = new Event($this->base, $fp, Event::READ | Event::PERSIST, array($this, "readLine")); $this->ev = new Event($this->base, $fp, Event::READ | Event::PERSIST, array($this, "readLine"));
$this->ev->add(); $this->ev->add();
@ -279,8 +279,10 @@ class ConsoleLoop extends Thread{
} }
} }
}else{ }else{
while($this->stop === false){ while($this->stop === false and ($line = fgets($fp)) !== false){
$this->readLine($fp); $this->line = $line;
$this->wait();
$this->line = false;
} }
} }
@fclose($fp); @fclose($fp);