1
0
mirror of https://github.com/danog/ext-pq.git synced 2024-12-02 09:18:02 +01:00
This commit is contained in:
Michael Wallner 2013-02-22 12:14:00 +01:00
parent 06d8f2976e
commit f00254ec86

View File

@ -26,22 +26,17 @@ $c->execAsync("SELECT a from generate_series(1,10) a", function($res) {
break; break;
} }
}); });
do { do {
while ($c->busy) { while ($c->busy) {
switch ($c->poll()) { $r = array($c->socket);
case pq\Connection::POLLING_READING: $w = $e = null;
$w=$e=array(); if (stream_select($r, $w, $e, null)) {
$r=array($c->socket); $c->poll();
stream:select($r,$w,$e,1);
break;
case pq\Connection::POLLING_WRITING:
$r=$e=array();
$w=array($c->socket);
stream_select($r,$w,$e,1);
break;
} }
} }
} while ($c->getResult()); } while ($c->getResult());
?> ?>
DONE DONE
--EXPECTF-- --EXPECTF--