better check for ready state on connection

darcs-hash:20080830171441-84dde-bb5373c4af2ae223d7b4b150f5a76404247a7570.gz
This commit is contained in:
Evan Prodromou 2008-08-30 13:14:41 -04:00
parent 0217a74f13
commit e4d42b2355
1 changed files with 3 additions and 3 deletions

View File

@ -619,9 +619,9 @@ class XMPPHP_XMLStream {
public function readyToProcess() {
$read = array($this->socket);
$write = null;
$except = null;
$write = array();
$except = array();
$updated = @stream_select($read, $write, $except, 0);
return $updated !== false;
return (($updated !== false) && ($updated > 0));
}
}